create user alloc for http if requested
Signed-off-by: Andy Green <andy.green@linaro.org>
This commit is contained in:
parent
54cb346320
commit
e803c82044
2 changed files with 12 additions and 0 deletions
|
@ -118,6 +118,13 @@ libwebsocket_read(struct libwebsocket_context *context,
|
|||
|
||||
lwsl_info("HTTP request for '%s'\n", lws_hdr_simple_ptr(wsi, WSI_TOKEN_GET_URI));
|
||||
|
||||
if (libwebsocket_ensure_user_space(wsi) == NULL) {
|
||||
/* drop the header info */
|
||||
if (wsi->u.hdr.ah)
|
||||
free(wsi->u.hdr.ah);
|
||||
goto bail;
|
||||
}
|
||||
|
||||
wsi->state = WSI_STATE_HTTP;
|
||||
n = 0;
|
||||
if (wsi->protocol->callback)
|
||||
|
|
|
@ -611,6 +611,11 @@ That's important because it uses a slot in the
|
|||
total number of client connections allowed set
|
||||
by MAX_CLIENTS.
|
||||
</blockquote>
|
||||
<h3>LWS_CALLBACK_HTTP_WRITEABLE</h3>
|
||||
<blockquote>
|
||||
you can write more down the http protocol
|
||||
link now.
|
||||
</blockquote>
|
||||
<h3>LWS_CALLBACK_HTTP_FILE_COMPLETION</h3>
|
||||
<blockquote>
|
||||
a file requested to be send down
|
||||
|
|
Loading…
Add table
Reference in a new issue