summaryrefslogtreecommitdiff
path: root/uclient-http.c
diff options
context:
space:
mode:
authorFelix Fietkau <nbd@openwrt.org>2014-03-21 21:32:01 +0100
committerFelix Fietkau <nbd@openwrt.org>2014-03-21 21:32:01 +0100
commit66b4e5035104658ad54ef48a4d04e61cba8d4e01 (patch)
treed032f5312d07138d6b7dce980231073209b7f1d1 /uclient-http.c
parentc62d6b1e6aabe9db364c3c1d9000048ea7bb1de5 (diff)
downloaduclient-66b4e5035104658ad54ef48a4d04e61cba8d4e01.tar.gz
set eof on HEAD requests after header end
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
Diffstat (limited to 'uclient-http.c')
-rw-r--r--uclient-http.c6
1 files changed, 6 insertions, 0 deletions
diff --git a/uclient-http.c b/uclient-http.c
index fcf3b9b..d4d4fba 100644
--- a/uclient-http.c
+++ b/uclient-http.c
@@ -133,6 +133,12 @@ static void uclient_parse_http_line(struct uclient_http *uh, char *data)
uclient_http_process_headers(uh);
if (uh->uc.cb->header_done)
uh->uc.cb->header_done(&uh->uc);
+
+ if (uh->req_type == REQ_HEAD) {
+ uh->eof = true;
+ uclient_notify_eof(uh);
+ }
+
return;
}