소스 검색

Compiler warning minor fixes

Evgeny Grin (Karlson2k) 8 년 전
부모
커밋
1d5c381b4e
3개의 변경된 파일13개의 추가작업 그리고 2개의 파일을 삭제
  1. 11 0
      src/microhttpd/connection.c
  2. 1 1
      src/microhttpd/daemon.c
  3. 1 1
      src/microhttpd/internal.h

+ 11 - 0
src/microhttpd/connection.c

@@ -1587,6 +1587,14 @@ MHD_connection_update_event_loop_info (struct MHD_Connection *connection)
         case MHD_CONNECTION_CLOSED:
 	  connection->event_loop_info = MHD_EVENT_LOOP_INFO_CLEANUP;
           return;       /* do nothing, not even reading */
+        case MHD_CONNECTION_IN_CLEANUP:
+          EXTRA_CHECK (0);
+          break;
+#ifdef UPGRADE_SUPPORT
+        case MHD_CONNECTION_UPGRADE:
+          EXTRA_CHECK (0);
+          break;
+#endif /* UPGRADE_SUPPORT */
         default:
           EXTRA_CHECK (0);
         }
@@ -2784,6 +2792,9 @@ MHD_connection_handle_write (struct MHD_Connection *connection)
         case MHD_TLS_CONNECTION_INIT:
           EXTRA_CHECK (0);
           break;
+        case MHD_CONNECTION_IN_CLEANUP:
+          EXTRA_CHECK (0);
+          break;
 #ifdef UPGRADE_SUPPORT
         case MHD_CONNECTION_UPGRADE:
           EXTRA_CHECK (0);

+ 1 - 1
src/microhttpd/daemon.c

@@ -779,7 +779,7 @@ urh_to_fdset (struct MHD_UpgradeResponseHandle *urh,
  * @param urh upgrade handle to update
  * @param rs read result from select()
  * @param ws write result from select()
- * @param ws except result from select()
+ * @param es except result from select()
  */
 static void
 urh_from_fdset (struct MHD_UpgradeResponseHandle *urh,

+ 1 - 1
src/microhttpd/internal.h

@@ -568,7 +568,7 @@ typedef ssize_t
  */
 typedef ssize_t
 (*TransmitCallback) (struct MHD_Connection *conn,
-                     const void *write_to,
+                     const void *read_from,
                      size_t max_bytes);