aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorChristian Grothoff <christian@grothoff.org>2013-06-21 16:16:52 +0000
committerChristian Grothoff <christian@grothoff.org>2013-06-21 16:16:52 +0000
commit2497b538344743211b7f0b188c8cfa2384969047 (patch)
treecb071d3531666e938cdbf7d131fc8140e83ea132
parent76f7883443bab649213b10e0a0ee12aa56442af7 (diff)
downloadlibmicrohttpd-2497b538344743211b7f0b188c8cfa2384969047.tar.gz
libmicrohttpd-2497b538344743211b7f0b188c8cfa2384969047.zip
make it clear that we intentionally ignore those return values, as there is no good way to handle those errors anyway
-rw-r--r--src/microhttpd/digestauth.c8
-rw-r--r--src/microhttpd/internal.h40
2 files changed, 44 insertions, 4 deletions
diff --git a/src/microhttpd/digestauth.c b/src/microhttpd/digestauth.c
index d6c26114..2c0e9526 100644
--- a/src/microhttpd/digestauth.c
+++ b/src/microhttpd/digestauth.c
@@ -317,19 +317,19 @@ check_nonce_nc (struct MHD_Connection *connection,
317 * then only increase the nonce counter by one. 317 * then only increase the nonce counter by one.
318 */ 318 */
319 319
320 pthread_mutex_lock (&connection->daemon->nnc_lock); 320 (void) pthread_mutex_lock (&connection->daemon->nnc_lock);
321 if (0 == nc) 321 if (0 == nc)
322 { 322 {
323 strcpy(connection->daemon->nnc[off].nonce, 323 strcpy(connection->daemon->nnc[off].nonce,
324 nonce); 324 nonce);
325 connection->daemon->nnc[off].nc = 0; 325 connection->daemon->nnc[off].nc = 0;
326 pthread_mutex_unlock (&connection->daemon->nnc_lock); 326 (void) pthread_mutex_unlock (&connection->daemon->nnc_lock);
327 return MHD_YES; 327 return MHD_YES;
328 } 328 }
329 if ( (nc <= connection->daemon->nnc[off].nc) || 329 if ( (nc <= connection->daemon->nnc[off].nc) ||
330 (0 != strcmp(connection->daemon->nnc[off].nonce, nonce)) ) 330 (0 != strcmp(connection->daemon->nnc[off].nonce, nonce)) )
331 { 331 {
332 pthread_mutex_unlock (&connection->daemon->nnc_lock); 332 (void) pthread_mutex_unlock (&connection->daemon->nnc_lock);
333#if HAVE_MESSAGES 333#if HAVE_MESSAGES
334 MHD_DLOG (connection->daemon, 334 MHD_DLOG (connection->daemon,
335 "Stale nonce received. If this happens a lot, you should probably increase the size of the nonce array.\n"); 335 "Stale nonce received. If this happens a lot, you should probably increase the size of the nonce array.\n");
@@ -337,7 +337,7 @@ check_nonce_nc (struct MHD_Connection *connection,
337 return MHD_NO; 337 return MHD_NO;
338 } 338 }
339 connection->daemon->nnc[off].nc = nc; 339 connection->daemon->nnc[off].nc = nc;
340 pthread_mutex_unlock (&connection->daemon->nnc_lock); 340 (void) pthread_mutex_unlock (&connection->daemon->nnc_lock);
341 return MHD_YES; 341 return MHD_YES;
342} 342}
343 343
diff --git a/src/microhttpd/internal.h b/src/microhttpd/internal.h
index 809c99e9..74ece408 100644
--- a/src/microhttpd/internal.h
+++ b/src/microhttpd/internal.h
@@ -93,6 +93,46 @@ enum MHD_PollActions
93 93
94 94
95/** 95/**
96 * State of the socket with respect to epoll.
97 */
98enum MHD_EpollState
99 {
100
101 /**
102 *
103 */
104 MHD_EPOLL_STATE_NOTHING = 0,
105
106 /**
107 *
108 */
109 MHD_EPOLL_STATE_NOTHING = 0,
110
111 /**
112 *
113 */
114 MHD_EPOLL_STATE_NOTHING = 0,
115
116 /**
117 *
118 */
119 MHD_EPOLL_STATE_NOTHING = 0,
120
121 /**
122 *
123 */
124 MHD_EPOLL_STATE_NOTHING = 0,
125
126 /**
127 *
128 */
129 MHD_EPOLL_STATE_NOTHING = 0,
130
131
132 };
133
134
135/**
96 * Socket descriptor and events we care about. 136 * Socket descriptor and events we care about.
97 */ 137 */
98struct MHD_Pollfd 138struct MHD_Pollfd