ref: 0f1b4081098678ddc580d05acdf41864258cd100
parent: 6a8d01560cd601404320e77d6628d0d2eb92aa6e
author: Timothy B. Terriberry <[email protected]>
date: Sun Dec 23 08:40:42 EST 2012
Add support for HTTP 308 Permanent Redirects.
--- a/src/http.c
+++ b/src/http.c
@@ -2200,7 +2200,7 @@
ret=op_http_parse_content_range(&range_first,&range_last,
&range_length,cdr);
if(OP_UNLIKELY(ret<0))return ret;
- /*"A response with satus code 206 (Partial Content) MUST NOTE
+ /*"A response with satus code 206 (Partial Content) MUST NOT
include a Content-Range field with a byte-range-resp-spec of
'*'."*/
if(status_code[2]=='6'
@@ -2306,7 +2306,9 @@
/*302 Found*/
case '2':
/*307 Temporary Redirect*/
- case '7':break;
+ case '7':
+ /*308 Permanent Redirect (defined by draft-reschke-http-status-308-07).*/
+ case '8':break;
/*305 Use Proxy: "The Location field gives the URI of the proxy."
TODO: This shouldn't actually be that hard to do.*/
case '5':return OP_EIMPL;
@@ -2314,7 +2316,7 @@
originally requested resource."
304 Not Modified: "The 304 response MUST NOT contain a message-body."
306 (Unused)
- 308...309 are not yet defined, so we don't know how to handle them.*/
+ 309 is not yet defined, so we don't know how to handle it.*/
default:return OP_FALSE;
}
_url=NULL;