From c635d5615add1db2eea17c9ae0b67e6671462cbd Mon Sep 17 00:00:00 2001 From: gdamore Date: Sat, 11 Oct 2025 13:20:16 +0000 Subject: deploy: b98e03b26bfc593326bd7c1d56fd69626f6a93cb --- ref/api/http.html | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'ref/api/http.html') diff --git a/ref/api/http.html b/ref/api/http.html index 45f469f4..11afe0c3 100644 --- a/ref/api/http.html +++ b/ref/api/http.html @@ -796,11 +796,11 @@ the response body may be set using either nng_http_handler_collect_body function has been called for the handler.

The HTTP status should be set for the transaction using nng_http_set_status.

-

Finally, the handler should finish the operation by calling the nng_aio_finish function +

Finally, the handler should finish the operation by calling the nng_aio_finish function after having set the status to NNG_OK. If any other status is set on the aio, then a generic 500 response will be created and sent, if possible, and the connection will be closed.

-

The aio may be scheduled for deferred completion using the nng_aio_start.

+

The aio may be scheduled for deferred completion using the nng_aio_start.

Serving Directories and Files

nng_err nng_http_handler_alloc_directory(nng_http_handler **hp, const char *path, const char *dirname);
 nng_err nng_http_handler_alloc_file(nng_http_handler **hp, const char *path, const char *filename);
-- 
cgit v1.2.3-70-g09d2