svn commit: trunk/busybox/networking
vda at busybox.net
vda at busybox.net
Sun Jun 22 16:28:04 UTC 2008
Author: vda
Date: 2008-06-22 09:28:02 -0700 (Sun, 22 Jun 2008)
New Revision: 22470
Log:
wget: accept code 204.
Modified:
trunk/busybox/networking/wget.c
Changeset:
Modified: trunk/busybox/networking/wget.c
===================================================================
--- trunk/busybox/networking/wget.c 2008-06-22 13:20:42 UTC (rev 22469)
+++ trunk/busybox/networking/wget.c 2008-06-22 16:28:02 UTC (rev 22470)
@@ -598,6 +598,31 @@
/* eat all remaining headers */;
goto read_response;
case 200:
+/*
+Response 204 doesn't say "null file", it says "metadata
+has changed but data didn't":
+
+"10.2.5 204 No Content
+The server has fulfilled the request but does not need to return
+an entity-body, and might want to return updated metainformation.
+The response MAY include new or updated metainformation in the form
+of entity-headers, which if present SHOULD be associated with
+the requested variant.
+
+If the client is a user agent, it SHOULD NOT change its document
+view from that which caused the request to be sent. This response
+is primarily intended to allow input for actions to take place
+without causing a change to the user agent's active document view,
+although any new or updated metainformation SHOULD be applied
+to the document currently in the user agent's active view.
+
+The 204 response MUST NOT include a message-body, and thus
+is always terminated by the first empty line after the header fields."
+
+However, in real world it was observed that some web servers
+(e.g. Boa/0.94.14rc21) simply use code 204 when file size is zero.
+*/
+ case 204:
break;
case 300: /* redirection */
case 301:
More information about the busybox-cvs
mailing list