An anonymous submitter filed bug #1299181
(http://curl.haxx.se/bug/view.cgi?id=1299181) that identified a silly problem with Content-Range: headers with the 'bytes' keyword written in a different case than all lowercase! It would cause a segfault!
This commit is contained in:
@@ -880,11 +880,11 @@ CURLcode Curl_readwrite(struct connectdata *conn,
|
||||
/* Content-Range: bytes [num]-
|
||||
Content-Range: bytes: [num]-
|
||||
|
||||
The second format was added August 1st 2000 by Igor
|
||||
Khristophorov since Sun's webserver JavaWebServer/1.1.1
|
||||
obviously sends the header this way! :-( */
|
||||
The second format was added since Sun's webserver
|
||||
JavaWebServer/1.1.1 obviously sends the header this way!
|
||||
*/
|
||||
|
||||
char *ptr = strstr(k->p, "bytes");
|
||||
char *ptr = Curl_strcasestr(k->p, "bytes");
|
||||
ptr+=5;
|
||||
|
||||
if(*ptr == ':')
|
||||
|
Reference in New Issue
Block a user