diff options
Diffstat (limited to 'doc/libmicrohttpd.texi')
-rw-r--r-- | doc/libmicrohttpd.texi | 42 |
1 files changed, 42 insertions, 0 deletions
diff --git a/doc/libmicrohttpd.texi b/doc/libmicrohttpd.texi index b5284c3c..d82ebeb3 100644 --- a/doc/libmicrohttpd.texi +++ b/doc/libmicrohttpd.texi | |||
@@ -1095,11 +1095,53 @@ Shutdown an HTTP daemon. | |||
1095 | Run webserver operations (without blocking unless in client callbacks). | 1095 | Run webserver operations (without blocking unless in client callbacks). |
1096 | This method should be called by clients in combination with | 1096 | This method should be called by clients in combination with |
1097 | @code{MHD_get_fdset()} if the client-controlled @code{select}-method is used. | 1097 | @code{MHD_get_fdset()} if the client-controlled @code{select}-method is used. |
1098 | @cindex select | ||
1099 | @cindex poll | ||
1100 | |||
1101 | This function will work for external @code{poll} and @code{select} mode. | ||
1102 | However, if using external @code{select} mode, you may want to | ||
1103 | instead use @code{MHD_run_from_select}, as it is more efficient. | ||
1104 | |||
1105 | @table @var | ||
1106 | @item daemon | ||
1107 | daemon to process connections of | ||
1108 | @end table | ||
1098 | 1109 | ||
1099 | Return @code{MHD_YES} on success, @code{MHD_NO} if this daemon was not | 1110 | Return @code{MHD_YES} on success, @code{MHD_NO} if this daemon was not |
1100 | started with the right options for this call. | 1111 | started with the right options for this call. |
1101 | @end deftypefun | 1112 | @end deftypefun |
1102 | 1113 | ||
1114 | @deftypefun int MHD_run_from_select (struct MHD_Daemon *daemon, const fd_set *read_fd_set, const fd_set *write_fd_set, const fd_set *except_fd_set) | ||
1115 | Run webserver operations given sets of ready socket handles. | ||
1116 | @cindex select | ||
1117 | |||
1118 | This method should be called by clients in combination with | ||
1119 | @code{MHD_get_fdset} if the client-controlled (external) | ||
1120 | select method is used. | ||
1121 | |||
1122 | You can use this function instead of @code{MHD_run} if you called | ||
1123 | @code{select} on the result from @code{MHD_get_fdset}. File descriptors in | ||
1124 | the sets that are not controlled by MHD will be ignored. Calling | ||
1125 | this function instead of @code{MHD_run} is more efficient as MHD will | ||
1126 | not have to call @code{select} again to determine which operations are | ||
1127 | ready. | ||
1128 | |||
1129 | @table @var | ||
1130 | @item daemon | ||
1131 | daemon to process connections of | ||
1132 | @item read_fd_set | ||
1133 | set of descriptors that must be ready for reading without blocking | ||
1134 | @item write_fd_set | ||
1135 | set of descriptors that must be ready for writing without blocking | ||
1136 | @item except_fd_set | ||
1137 | ignored, can be NULL | ||
1138 | @end table | ||
1139 | |||
1140 | Return @code{MHD_YES} on success, @code{MHD_NO} on serious internal | ||
1141 | errors. | ||
1142 | |||
1143 | @end deftypefun | ||
1144 | |||
1103 | 1145 | ||
1104 | @deftypefun void MHD_add_connection (struct MHD_Daemon *daemon, int client_socket, const struct sockaddr *addr, socklen_t addrlen) | 1146 | @deftypefun void MHD_add_connection (struct MHD_Daemon *daemon, int client_socket, const struct sockaddr *addr, socklen_t addrlen) |
1105 | Add another client connection to the set of connections | 1147 | Add another client connection to the set of connections |