Home |
Function http_find_string_value Function http_add_get_functions Function http_add_post_functions Function http_server_daemon Function http_set_browser_list Function http_set_put_function |
Function http_server_daemonThis function is the HTTP server. int http_server_daemon(void); Parametersreturn valueOn failure, the function returns SOCKET_ERROR and xn_getlasterror and xn_geterror_string return the error value. Error Codes further describes each error. If the function succeeds, it never returns. Executing the Web server consists of this single function call. The function http_server_daemon handles all http server requests coming in on port CFG_WWW_PORT. It loops forever processing browser requests. For each established valid connection, a thread is spawned to process the request. http_server_daemon will return only if an error is detected. One TCP socket is allocated to listen for requests and one TCP socket is allocated to process each request. The socket is closed after the request has been processed. Function http_add_post_functions
|