Function esp_idf_svc::hal::sys::httpd_queue_work
source · pub unsafe extern "C" fn httpd_queue_work(
handle: *mut c_void,
work: Option<unsafe extern "C" fn(_: *mut c_void)>,
arg: *mut c_void,
) -> i32
Expand description
@brief Queue execution of a function in HTTPD’s context
This API queues a work function for asynchronous execution
@note Some protocols require that the web server generate some asynchronous data and send it to the persistently opened connection. This facility is for use by such protocols.
@param[in] handle Handle to server returned by httpd_start @param[in] work Pointer to the function to be executed in the HTTPD’s context @param[in] arg Pointer to the arguments that should be passed to this function
@return
- ESP_OK : On successfully queueing the work
- ESP_FAIL : Failure in ctrl socket
- ESP_ERR_INVALID_ARG : Null arguments