add support for 204 (no content)
authorFelix Fietkau <nbd@openwrt.org>
Sat, 29 Mar 2014 22:31:54 +0000 (23:31 +0100)
committerFelix Fietkau <nbd@openwrt.org>
Sat, 29 Mar 2014 22:31:54 +0000 (23:31 +0100)
Signed-off-by: Felix Fietkau <nbd@openwrt.org>
uclient-http.c

index f16d29d399c2a2936b8c62649fd8f726b74b3a78..7a54cce5c38a4b0e997157c984a305cdcea4aed5 100644 (file)
@@ -518,7 +518,7 @@ static void uclient_http_headers_complete(struct uclient_http *uh)
        if (uh->uc.cb->header_done)
                uh->uc.cb->header_done(&uh->uc);
 
-       if (uh->req_type == REQ_HEAD) {
+       if (uh->req_type == REQ_HEAD || uh->uc.status_code == 204) {
                uh->eof = true;
                uclient_notify_eof(uh);
        }