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

Unified Diff: chrome/renderer/chrome_content_renderer_client.cc

Issue 1568073002: Reduce string copies in GURL creation (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: 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
Index: chrome/renderer/chrome_content_renderer_client.cc
diff --git a/chrome/renderer/chrome_content_renderer_client.cc b/chrome/renderer/chrome_content_renderer_client.cc
index ef2fd79a5b2ec24bfb2448a14bf3c58ca2e7676f..fed63a3c8f3215498a46cb35c72d55372ccda9ea 100644
--- a/chrome/renderer/chrome_content_renderer_client.cc
+++ b/chrome/renderer/chrome_content_renderer_client.cc
@@ -89,6 +89,7 @@
#include "net/base/net_errors.h"
#include "ppapi/c/private/ppb_pdf.h"
#include "ppapi/shared_impl/ppapi_switches.h"
+#include "third_party/WebKit/public/platform/URLConversion.h"
#include "third_party/WebKit/public/platform/WebURL.h"
#include "third_party/WebKit/public/platform/WebURLError.h"
#include "third_party/WebKit/public/platform/WebURLRequest.h"
@@ -557,8 +558,8 @@ bool ChromeContentRendererClient::OverrideCreatePlugin(
ChromeViewHostMsg_GetPluginInfo_Output output;
WebString top_origin = frame->top()->securityOrigin().toString();
render_frame->Send(new ChromeViewHostMsg_GetPluginInfo(
- render_frame->GetRoutingID(), url, GURL(top_origin), orig_mime_type,
- &output));
+ render_frame->GetRoutingID(), url, blink::WebStringToGURL(top_origin),
+ orig_mime_type, &output));
*plugin = CreatePlugin(render_frame, frame, params, output);
#else // !defined(ENABLE_PLUGINS)

Powered by Google App Engine
This is Rietveld 408576698