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

Unified Diff: webkit/support/webkit_support.cc

Issue 6246036: FilePath: Remove most of ToWStringHack, adding a LossyDisplayName() (Closed) Base URL: svn://svn.chromium.org/chrome/trunk/src
Patch Set: Created 9 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: webkit/support/webkit_support.cc
diff --git a/webkit/support/webkit_support.cc b/webkit/support/webkit_support.cc
index 2e893f986e4348ec75e600a8883829afdeb45759..c4e40d808a17de6586a1d4b08f63703e73d202ec 100644
--- a/webkit/support/webkit_support.cc
+++ b/webkit/support/webkit_support.cc
@@ -289,8 +289,9 @@ WebKit::WebApplicationCacheHost* CreateApplicationCacheHost(
}
WebKit::WebString GetWebKitRootDir() {
- FilePath path = GetWebKitRootDirFilePath();
- return WebKit::WebString::fromUTF8(WideToUTF8(path.ToWStringHack()).c_str());
+ // In theory you cannot safely convert a path to a string, but this code
+ // is only used by tests.
+ return GetWebKitRootDirFilePath().LossyDisplayName();
}
void SetUpGLBindings(GLBindingPreferences bindingPref) {

Powered by Google App Engine
This is Rietveld 408576698