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

Unified Diff: url/origin.cc

Issue 1658913002: Make extensions use a correct same-origin check. (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Respond to comments. Created 4 years, 11 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
« extensions/common/url_pattern_set.cc ('K') | « url/origin.h ('k') | no next file » | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: url/origin.cc
diff --git a/url/origin.cc b/url/origin.cc
index a0ec2f803e6f2547bdcc443c338d06b68cefbb3a..97e24f208d5b2098df01078615a7791503d30fbf 100644
--- a/url/origin.cc
+++ b/url/origin.cc
@@ -80,4 +80,8 @@ std::ostream& operator<<(std::ostream& out, const url::Origin& origin) {
return out << origin.Serialize();
}
+bool IsSameOriginWith(const GURL& a, const GURL& b) {
+ return Origin(a).IsSameOriginWith(Origin(b));
+}
+
} // namespace url
« extensions/common/url_pattern_set.cc ('K') | « url/origin.h ('k') | no next file » | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698