Chromium Code Reviews
chromiumcodereview-hr@appspot.gserviceaccount.com (chromiumcodereview-hr) | Please choose your nickname with Settings | Help | Chromium Project | Gerrit Changes | Sign out
(543)

Unified Diff: net/url_request/url_request_job.h

Issue 212543005: Do not copy reference fragments for overridden redirects. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Address mmenke's comments Created 6 years, 9 months ago
Use n/p to move between diff chunks; N/P to move between comments. Draft comments are only viewable by you.
Jump to:
View side-by-side diff with in-line comments
Download patch
Index: net/url_request/url_request_job.h
diff --git a/net/url_request/url_request_job.h b/net/url_request/url_request_job.h
index c6f7ba4e4bab705cc7cfd9e2b0527cc72363fd4c..a68937b921a0cade38765a2dd3128fc9cdfa9d10 100644
--- a/net/url_request/url_request_job.h
+++ b/net/url_request/url_request_job.h
@@ -157,6 +157,14 @@ class NET_EXPORT URLRequestJob
// The default implementation inspects the response_info_.
virtual bool IsRedirectResponse(GURL* location, int* http_status_code);
+ // Called to determine if it is okay to copy the reference fragment from the
+ // original URL to the redirection target when the redirection target has no
+ // reference fragment.
mmenke 2014/04/01 20:26:51 nit: Also mention that it's only copied if locati
robwu 2014/04/01 20:46:33 Done.
+ //
+ // The default implementation returns true.
+ virtual bool IsRedirectFragmentModificationAllowed(
+ const GURL& location) const OVERRIDE;
mmenke 2014/04/01 20:26:51 nit: Think "CopyFragmentOnRedirect" may be a litt
robwu 2014/04/01 20:46:33 Done. Now the method signatures fit on one line as
+
// Called to determine if it is okay to redirect this job to the specified
// location. This may be used to implement protocol-specific restrictions.
// If this function returns false, then the URLRequest will fail

Powered by Google App Engine
This is Rietveld 408576698