| Index: components/plugins/renderer/mobile_youtube_plugin.cc
|
| diff --git a/components/plugins/renderer/mobile_youtube_plugin.cc b/components/plugins/renderer/mobile_youtube_plugin.cc
|
| index 455640b0fbc07b849cb2638b8751cd698a4bb162..d98b74ddf38b2c20540a028b7f9be320e93502cb 100644
|
| --- a/components/plugins/renderer/mobile_youtube_plugin.cc
|
| +++ b/components/plugins/renderer/mobile_youtube_plugin.cc
|
| @@ -28,13 +28,13 @@ namespace {
|
|
|
| std::string GetYoutubeVideoId(const blink::WebPluginParams& params) {
|
| GURL url(params.url);
|
| - std::string video_id = url.path().substr(strlen(kSlashVSlash));
|
| + base::StringPiece video_id = url.path().substr(strlen(kSlashVSlash));
|
|
|
| // Extract just the video id
|
| size_t video_id_end = video_id.find('&');
|
| if (video_id_end != std::string::npos)
|
| video_id = video_id.substr(0, video_id_end);
|
| - return video_id;
|
| + return video_id.as_string();
|
| }
|
|
|
| std::string HtmlData(const blink::WebPluginParams& params,
|
| @@ -44,7 +44,7 @@ std::string HtmlData(const blink::WebPluginParams& params,
|
| return webui::GetI18nTemplateHtml(template_html, &values);
|
| }
|
|
|
| -bool IsValidYouTubeVideo(const std::string& path) {
|
| +bool IsValidYouTubeVideo(const base::StringPiece& path) {
|
| unsigned len = strlen(kSlashVSlash);
|
|
|
| // check for more than just /v/ or /e/.
|
|
|