libmicrohttpd

HTTP/1.x server C library (MHD 1.x, stable)
Log | Files | Refs | Submodules | README | LICENSE

commit 61876d057853557018e73cf4bde84d8021d11fbe
parent f52cd063f107d39fb14e4e3830666051321f403d
Author: Christian Grothoff <christian@grothoff.org>
Date:   Sun, 11 Jan 2015 00:31:54 +0000

fix documentation

Diffstat:
Mdoc/libmicrohttpd.texi | 31++++++++++++++++++++-----------
1 file changed, 20 insertions(+), 11 deletions(-)

diff --git a/doc/libmicrohttpd.texi b/doc/libmicrohttpd.texi @@ -1097,17 +1097,26 @@ the data being uploaded (excluding headers): @cindex POST method @cindex PUT method -@itemize -@item -for a @code{POST} that fits into memory and that is encoded with a -supported encoding, the @code{POST} data will @strong{NOT} be given in -@var{upload_data} and is instead available as part of -@code{MHD_get_connection_values()}; - -@item -very large @code{POST} data @strong{will} be made available -incrementally in @var{upload_data}; -@end itemize +@code{POST} data @strong{will} be made available +incrementally in @var{upload_data}; even if @code{POST} +data is available, the first time the callback is +invoked there won't be upload data, as this is done +just after MHD parses the headers. If supported by +the client and the HTTP version, the application can +at this point queue an error response to possibly +avoid the upload entirely. If no response is generated, +MHD will (if required) automatically send a 100 CONTINUE +reply to the client. + +Afterwards, POST data will be passed to the callback +to be processed incrementally by the application. The +application may return @code{MHD_NO} to forcefully +terminate the TCP connection without generating a +proper HTTP response. Once all of the upload data has +been provided to the application, the application +will be called again with 0 bytes of upload data. +At this point, a response should be queued to complete +the handling of the request. @item upload_data_size set initially to the size of the @var{upload_data} provided; this