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

Unified Diff: content/child/storage_util.cc

Issue 2382973002: Convert WebSecurityOrigin -> GURL without re-parsing the url (Closed)
Patch Set: rebase on #427122 Created 4 years, 2 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: content/child/storage_util.cc
diff --git a/content/child/storage_util.cc b/content/child/storage_util.cc
index 6e440bf96e82347bfd2a961d01d4fef1fe736ee1..7770c0fa98978349685baada35fddb2e531f906c 100644
--- a/content/child/storage_util.cc
+++ b/content/child/storage_util.cc
@@ -7,6 +7,7 @@
#include "third_party/WebKit/public/platform/URLConversion.h"
#include "third_party/WebKit/public/platform/WebSecurityOrigin.h"
#include "url/gurl.h"
+#include "url/origin.h"
namespace content {
@@ -20,7 +21,7 @@ GURL WebSecurityOriginToGURL(const blink::WebSecurityOrigin& security_origin) {
security_origin.host().utf8() == "" && security_origin.port() == 0) {
return GURL("file:///");
}
- return blink::WebStringToGURL(security_origin.toString());
+ return url::Origin(security_origin).GetURL();
}
} // namespace content
« no previous file with comments | « content/child/notifications/notification_manager.cc ('k') | content/renderer/dom_storage/local_storage_namespace.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698