1
0
mirror of https://github.com/moparisthebest/wget synced 2024-07-03 16:38:41 -04:00

[svn] Accept HTTP status 307 as redirect.

This commit is contained in:
hniksic 2003-10-14 16:32:15 -07:00
parent c6dcc539f8
commit 31d919b23d
2 changed files with 9 additions and 3 deletions

View File

@ -1,3 +1,7 @@
2003-10-15 Hrvoje Niksic <hniksic@xemacs.org>
* http.c: Consider status 307 a valid redirect.
2003-10-15 Philip Stadermann <philip.stadermann@credativ.de> 2003-10-15 Philip Stadermann <philip.stadermann@credativ.de>
* ftp.c (ftp_retrieve_glob): Correctly loop through the list whose * ftp.c (ftp_retrieve_glob): Correctly loop through the list whose

View File

@ -89,8 +89,9 @@ struct cookie_jar *wget_cookie_jar;
/* Some status code validation macros: */ /* Some status code validation macros: */
#define H_20X(x) (((x) >= 200) && ((x) < 300)) #define H_20X(x) (((x) >= 200) && ((x) < 300))
#define H_PARTIAL(x) ((x) == HTTP_STATUS_PARTIAL_CONTENTS) #define H_PARTIAL(x) ((x) == HTTP_STATUS_PARTIAL_CONTENTS)
#define H_REDIRECTED(x) (((x) == HTTP_STATUS_MOVED_PERMANENTLY) \ #define H_REDIRECTED(x) ((x) == HTTP_STATUS_MOVED_PERMANENTLY \
|| ((x) == HTTP_STATUS_MOVED_TEMPORARILY)) || (x) == HTTP_STATUS_MOVED_TEMPORARILY \
|| (x) == HTTP_STATUS_TEMPORARY_REDIRECT)
/* HTTP/1.0 status codes from RFC1945, provided for reference. */ /* HTTP/1.0 status codes from RFC1945, provided for reference. */
/* Successful 2xx. */ /* Successful 2xx. */
@ -105,6 +106,7 @@ struct cookie_jar *wget_cookie_jar;
#define HTTP_STATUS_MOVED_PERMANENTLY 301 #define HTTP_STATUS_MOVED_PERMANENTLY 301
#define HTTP_STATUS_MOVED_TEMPORARILY 302 #define HTTP_STATUS_MOVED_TEMPORARILY 302
#define HTTP_STATUS_NOT_MODIFIED 304 #define HTTP_STATUS_NOT_MODIFIED 304
#define HTTP_STATUS_TEMPORARY_REDIRECT 307
/* Client error 4xx. */ /* Client error 4xx. */
#define HTTP_STATUS_BAD_REQUEST 400 #define HTTP_STATUS_BAD_REQUEST 400