From: Daniel Stenberg Date: Thu, 10 May 2001 11:29:47 +0000 (+0000) Subject: Ingo Wilken's patch to support multiple spaces after "Location:" X-Git-Tag: curl-7_8-pre2~93 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=dc6da007ad1d1f5c2ae6caa111400f6f652aba6f;p=thirdparty%2Fcurl.git Ingo Wilken's patch to support multiple spaces after "Location:" --- diff --git a/lib/transfer.c b/lib/transfer.c index df52014462..5823921484 100644 --- a/lib/transfer.c +++ b/lib/transfer.c @@ -517,8 +517,14 @@ Transfer(struct connectdata *c_conn) char *start=p; char backup; - start += 10; /* pass "Location: " */ + start += 9; /* pass "Location:" */ + + /* Skip spaces and tabs. We do this to support multiple + white spaces after the "Location:" keyword. */ + while(*start && isspace((int)*start )) + start++; ptr = start; /* start scanning here */ + /* scan through the string to find the end */ while(*ptr && !isspace((int)*ptr)) ptr++;