diff options
Diffstat (limited to 'src/microhttpd/internal.h')
-rw-r--r-- | src/microhttpd/internal.h | 58 |
1 files changed, 54 insertions, 4 deletions
diff --git a/src/microhttpd/internal.h b/src/microhttpd/internal.h index a810d319..c1524330 100644 --- a/src/microhttpd/internal.h +++ b/src/microhttpd/internal.h | |||
@@ -147,22 +147,22 @@ enum MHD_ConnectionEventLoopInfo | |||
147 | /** | 147 | /** |
148 | * We are waiting to be able to read. | 148 | * We are waiting to be able to read. |
149 | */ | 149 | */ |
150 | MHD_EVENT_LOOP_INFO_READ = 0, | 150 | MHD_EVENT_LOOP_INFO_READ = 1, |
151 | 151 | ||
152 | /** | 152 | /** |
153 | * We are waiting to be able to write. | 153 | * We are waiting to be able to write. |
154 | */ | 154 | */ |
155 | MHD_EVENT_LOOP_INFO_WRITE = 1, | 155 | MHD_EVENT_LOOP_INFO_WRITE = 2, |
156 | 156 | ||
157 | /** | 157 | /** |
158 | * We are waiting for the application to provide data. | 158 | * We are waiting for the application to provide data. |
159 | */ | 159 | */ |
160 | MHD_EVENT_LOOP_INFO_BLOCK = 2, | 160 | MHD_EVENT_LOOP_INFO_BLOCK = 4, |
161 | 161 | ||
162 | /** | 162 | /** |
163 | * We are finished and are awaiting cleanup. | 163 | * We are finished and are awaiting cleanup. |
164 | */ | 164 | */ |
165 | MHD_EVENT_LOOP_INFO_CLEANUP = 3 | 165 | MHD_EVENT_LOOP_INFO_CLEANUP = 8 |
166 | }; | 166 | }; |
167 | 167 | ||
168 | 168 | ||
@@ -886,6 +886,56 @@ struct MHD_Connection | |||
886 | int resuming; | 886 | int resuming; |
887 | }; | 887 | }; |
888 | 888 | ||
889 | |||
890 | /** | ||
891 | * Handle given to the application to manage special | ||
892 | * actions relating to MHD responses that "upgrade" | ||
893 | * the HTTP protocol (i.e. to WebSockets). | ||
894 | */ | ||
895 | struct MHD_UpgradeResponseHandle | ||
896 | { | ||
897 | |||
898 | /** | ||
899 | * Kept in a DLL per daemon. | ||
900 | */ | ||
901 | struct MHD_UpgradeResponseHandle *next; | ||
902 | |||
903 | /** | ||
904 | * Kept in a DLL per daemon. | ||
905 | */ | ||
906 | struct MHD_UpgradeResponseHandle *prev; | ||
907 | |||
908 | /** | ||
909 | * The connection for which this is an upgrade handle. Note that | ||
910 | * because a response may be shared over many connections, this may | ||
911 | * not be the only upgrade handle for the response of this connection. | ||
912 | */ | ||
913 | struct MHD_Connection *connection; | ||
914 | |||
915 | /** | ||
916 | * The socket we gave to the application (r/w). | ||
917 | */ | ||
918 | MHD_socket app_socket; | ||
919 | |||
920 | /** | ||
921 | * IO-state of the @e app_socket. | ||
922 | */ | ||
923 | enum MHD_ConnectionEventLoopInfo celi_app; | ||
924 | |||
925 | /** | ||
926 | * If @a app_sock was a socketpair, our end of it, otherwise | ||
927 | * #MHD_INVALID_SOCKET; (r/w). | ||
928 | */ | ||
929 | MHD_socket mhd_socket; | ||
930 | |||
931 | /** | ||
932 | * IO-state of the @e mhd_socket. | ||
933 | */ | ||
934 | enum MHD_ConnectionEventLoopInfo celi_mhd; | ||
935 | |||
936 | }; | ||
937 | |||
938 | |||
889 | /** | 939 | /** |
890 | * Signature of function called to log URI accesses. | 940 | * Signature of function called to log URI accesses. |
891 | * | 941 | * |