mirror of
https://github.com/mozilla/gecko-dev.git
synced 2024-11-28 23:31:56 +00:00
Fixes bug 84794 (part 2) "Problem with HTTP basic authentication and cookies"
r=gagan, sr=dougt, a=chofmann
This commit is contained in:
parent
8bdc6dcede
commit
d580655f64
@ -176,6 +176,10 @@ nsCookieHTTPNotify::OnModifyRequest(nsIHttpChannel *aHttpChannel)
|
||||
rv = mCookieService->GetCookieStringFromHttp(pURL, pFirstURL, &cookie);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
// Clear any existing Cookie request header
|
||||
rv = aHttpChannel->SetRequestHeader("Cookie", nsnull);
|
||||
if (NS_FAILED(rv)) return rv;
|
||||
|
||||
// Set the cookie into the request headers
|
||||
if (cookie && *cookie)
|
||||
rv = aHttpChannel->SetRequestHeader("Cookie", cookie);
|
||||
|
Loading…
Reference in New Issue
Block a user