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

Unified Diff: content/child/simple_webmimeregistry_impl.cc

Issue 1259673002: Make UTF16ToASCII and UTF16TOUTF8 take a StringPiece (Closed) Base URL: https://chromium.googlesource.com/chromium/src.git@master
Patch Set: Created 5 years, 5 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/simple_webmimeregistry_impl.cc
diff --git a/content/child/simple_webmimeregistry_impl.cc b/content/child/simple_webmimeregistry_impl.cc
index a25e2aecdfb459ed56a3249cd1e267ecf9dd199e..a3b1c7f527beea55a10f839431abcca83299efa4 100644
--- a/content/child/simple_webmimeregistry_impl.cc
+++ b/content/child/simple_webmimeregistry_impl.cc
@@ -19,8 +19,9 @@ namespace content {
//static
std::string SimpleWebMimeRegistryImpl::ToASCIIOrEmpty(const WebString& string) {
- return base::IsStringASCII(string) ? base::UTF16ToASCII(string)
- : std::string();
+ return base::IsStringASCII(string)
+ ? base::UTF16ToASCII(base::StringPiece16(string))
+ : std::string();
}
WebMimeRegistry::SupportsType SimpleWebMimeRegistryImpl::supportsMIMEType(
« no previous file with comments | « content/child/notifications/notification_manager.cc ('k') | content/renderer/accessibility/blink_ax_tree_source.cc » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld 408576698