diff options
Diffstat (limited to 'doc/man7/libweb_http.7')
| -rw-r--r-- | doc/man7/libweb_http.7 | 19 |
1 files changed, 19 insertions, 0 deletions
diff --git a/doc/man7/libweb_http.7 b/doc/man7/libweb_http.7 index f11c1ef..c3bec8b 100644 --- a/doc/man7/libweb_http.7 +++ b/doc/man7/libweb_http.7 @@ -562,6 +562,7 @@ struct http_response unsigned long long \fIn\fP; size_t \fIn_headers\fP; void (*\fIfree\fP)(void *); + int (*\fIstep\fP)(const struct http_payload *, struct http_response *, void *); }; .EE .in @@ -669,6 +670,24 @@ is a valid pointer. Otherwise, .I free must be a null pointer. +.I step +allows implementations to generate a response in a non-blocking manner. +When a response is not immediately available when a payload is received, +.I step +must be assigned to a function that can generate it later. +.I libweb +shall then call this function immediately later, +without blocking other clients. +Assigning +.I step +to a null pointer falls back to the default behaviour +i.e., a response is returned immediately. +Note that a non-null +.I step +shall always take priority, thus ignoring any other information inside the +.I "struct http_response" +instance. + .SS Transport Layer Security (TLS) By design, .I libweb |
