aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEvgeny Grin (Karlson2k) <k2k@narod.ru>2017-03-16 17:04:08 +0300
committerEvgeny Grin (Karlson2k) <k2k@narod.ru>2017-03-16 17:04:08 +0300
commitb3e48b50908ebd754da1fac9cc3b26d567413daa (patch)
tree8929bcad1a27b8bfcde3cc365a51db57ea793eb0
parent3f9f4d8b53a403c82949847d59d7e544ae8f4ea6 (diff)
downloadlibmicrohttpd-b3e48b50908ebd754da1fac9cc3b26d567413daa.tar.gz
libmicrohttpd-b3e48b50908ebd754da1fac9cc3b26d567413daa.zip
Fixed compiler warnings, updated ChangeLog.
-rw-r--r--ChangeLog5
-rw-r--r--src/microhttpd/daemon.c2
-rw-r--r--src/microhttpd/test_upgrade.c13
3 files changed, 16 insertions, 4 deletions
diff --git a/ChangeLog b/ChangeLog
index fa4e0f28..7cca315c 100644
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,8 @@
1Thu Mar 16 16:49:07 MSK 2017
2 Added ability to get actual daemon flags via MHD_get_daemon_info().
3 Fixed test_upgrade to work in request mode.
4 Fixed compiler warnings in test_upgrade. -EG
5
1Wed Mar 15 23:29:59 MSK 2017 6Wed Mar 15 23:29:59 MSK 2017
2 Prevented socket read/write if connection is suspended. 7 Prevented socket read/write if connection is suspended.
3 Added missing resets of 'connection->in_idle'. 8 Added missing resets of 'connection->in_idle'.
diff --git a/src/microhttpd/daemon.c b/src/microhttpd/daemon.c
index ec3f325a..185421c7 100644
--- a/src/microhttpd/daemon.c
+++ b/src/microhttpd/daemon.c
@@ -101,6 +101,7 @@
101static void 101static void
102close_all_connections (struct MHD_Daemon *daemon); 102close_all_connections (struct MHD_Daemon *daemon);
103 103
104#ifdef EPOLL_SUPPORT
104 105
105/** 106/**
106 * Do epoll()-based processing (this function is allowed to 107 * Do epoll()-based processing (this function is allowed to
@@ -114,6 +115,7 @@ static int
114MHD_epoll (struct MHD_Daemon *daemon, 115MHD_epoll (struct MHD_Daemon *daemon,
115 int may_block); 116 int may_block);
116 117
118#endif /* EPOLL_SUPPORT */
117 119
118/** 120/**
119 * Default implementation of the panic function, 121 * Default implementation of the panic function,
diff --git a/src/microhttpd/test_upgrade.c b/src/microhttpd/test_upgrade.c
index 06dac795..fe72a70f 100644
--- a/src/microhttpd/test_upgrade.c
+++ b/src/microhttpd/test_upgrade.c
@@ -888,6 +888,7 @@ run_mhd_select_loop (struct MHD_Daemon *daemon)
888 } 888 }
889} 889}
890 890
891#ifdef HAVE_POLL
891 892
892/** 893/**
893 * Run the MHD external event loop using select. 894 * Run the MHD external event loop using select.
@@ -899,8 +900,10 @@ run_mhd_poll_loop (struct MHD_Daemon *daemon)
899{ 900{
900 abort (); /* currently not implementable with existing MHD API */ 901 abort (); /* currently not implementable with existing MHD API */
901} 902}
903#endif /* HAVE_POLL */
902 904
903 905
906#ifdef EPOLL_SUPPORT
904/** 907/**
905 * Run the MHD external event loop using select. 908 * Run the MHD external event loop using select.
906 * 909 *
@@ -938,7 +941,7 @@ run_mhd_epoll_loop (struct MHD_Daemon *daemon)
938 MHD_run (daemon); 941 MHD_run (daemon);
939 } 942 }
940} 943}
941 944#endif /* EPOLL_SUPPORT */
942 945
943/** 946/**
944 * Run the MHD external event loop using select. 947 * Run the MHD external event loop using select.
@@ -949,14 +952,16 @@ static void
949run_mhd_loop (struct MHD_Daemon *daemon, 952run_mhd_loop (struct MHD_Daemon *daemon,
950 int flags) 953 int flags)
951{ 954{
952 if (0 != (flags & MHD_USE_POLL)) 955 if (0 == (flags & (MHD_USE_POLL | MHD_USE_EPOLL)))
956 run_mhd_select_loop (daemon);
957#ifdef HAVE_POLL
958 else if (0 != (flags & MHD_USE_POLL))
953 run_mhd_poll_loop (daemon); 959 run_mhd_poll_loop (daemon);
960#endif /* HAVE_POLL */
954#if EPOLL_SUPPORT 961#if EPOLL_SUPPORT
955 else if (0 != (flags & MHD_USE_EPOLL)) 962 else if (0 != (flags & MHD_USE_EPOLL))
956 run_mhd_epoll_loop (daemon); 963 run_mhd_epoll_loop (daemon);
957#endif 964#endif
958 else if (0 == (flags & (MHD_USE_POLL | MHD_USE_EPOLL)))
959 run_mhd_select_loop (daemon);
960 else 965 else
961 abort (); 966 abort ();
962} 967}