[webkit-reviews] review requested: [Bug 11611] REGRESSION: No http referer header sent on XMLHttpRequest : [Attachment 12185] proposed fix

bugzilla-request-daemon at macosforge.org bugzilla-request-daemon at macosforge.org
Wed Jan 3 05:57:34 PST 2007


Alexey Proskuryakov <ap at webkit.org> has asked  for review:
Bug 11611: REGRESSION: No http referer header sent on XMLHttpRequest
http://bugs.webkit.org/show_bug.cgi?id=11611

Attachment 12185: proposed fix
http://bugs.webkit.org/attachment.cgi?id=12185&action=edit

------- Additional Comments from Alexey Proskuryakov <ap at webkit.org>
As of r18544, I could only reproduce this with async requests. One reason was
that String::operator!() is used to check if a referer has been already set,
and the default implementation of this operator doesn't work correctly:

    if (!hideReferrer && !request.httpReferrer())
	newRequest.setHTTPReferrer(fl->outgoingReferrer());

Another reason was that ResourceRequest->NSURLRequest conversion logic was a
bit messed up in SubresourceLoader::create(). I rewrote this method to use
ResourceRequest::nsURLRequest(). One thing I'm not quite sure about is a FIXME
that I removed:

// FIXME: Because of <rdar://problem/4803505>, the method has to be set before
the body.

It was added in r17294 without a test or much explanation, and seems to be
obsolete.



More information about the webkit-reviews mailing list