projects
/
platform
/
upstream
/
libwebsockets.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
| inline |
side by side
(parent:
3ae1bad
)
[PATCH] added timeout reset in serve_http_file_fragment to prevent timeout on big...
author
=?UTF-8?q?Dalibor=20Ba=C4=8Da?=
<dalibor.baca@gmail.com>
Sat, 10 Oct 2015 16:17:42 +0000
(18:17 +0200)
committer
Andy Green
<andy.green@linaro.org>
Sun, 11 Oct 2015 08:14:11 +0000
(16:14 +0800)
lib/output.c
patch
|
blob
|
history
diff --git
a/lib/output.c
b/lib/output.c
index
b914f28
..
6c5be88
100644
(file)
--- a/
lib/output.c
+++ b/
lib/output.c
@@
-538,6
+538,7
@@
LWS_VISIBLE int libwebsockets_serve_http_file_fragment(
if (n < 0)
return -1; /* caller will close */
if (n) {
+ libwebsocket_set_timeout(wsi, PENDING_TIMEOUT_HTTP_CONTENT, AWAITING_TIMEOUT);
wsi->u.http.filepos += n;
m = libwebsocket_write(wsi, context->service_buffer, n,
wsi->u.http.filepos == wsi->u.http.filelen ? LWS_WRITE_HTTP_FINAL : LWS_WRITE_HTTP);