aboutsummaryrefslogtreecommitdiff
path: root/networking/httpd.c
diff options
context:
space:
mode:
authorDenys Vlasenko <vda.linux@googlemail.com>2019-04-19 14:03:37 +0200
committerDenys Vlasenko <vda.linux@googlemail.com>2019-04-19 14:03:37 +0200
commitaf6012a1a7dcfc8eb2321e3adaaae3a0778d5a15 (patch)
treebe0b03f7939d7412fc8537e5dd81758151ccd3b2 /networking/httpd.c
parentbca888a73ef755e7fe52ac7aff5bd884f71d32f9 (diff)
downloadbusybox-af6012a1a7dcfc8eb2321e3adaaae3a0778d5a15.tar.gz
httpd: do not set alarm() timeout if we read cached header
Signed-off-by: Denys Vlasenko <vda.linux@googlemail.com>
Diffstat (limited to 'networking/httpd.c')
-rw-r--r--networking/httpd.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/networking/httpd.c b/networking/httpd.c
index d06bc2776..aa8ce8dcb 100644
--- a/networking/httpd.c
+++ b/networking/httpd.c
@@ -1253,10 +1253,10 @@ static unsigned get_line(void)
unsigned count;
char c;
- alarm(HEADER_READ_TIMEOUT);
count = 0;
while (1) {
if (hdr_cnt <= 0) {
+ alarm(HEADER_READ_TIMEOUT);
hdr_cnt = safe_read(STDIN_FILENO, hdr_buf, sizeof_hdr_buf);
if (hdr_cnt <= 0)
goto ret;