diff options
author | evan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-02-04 22:31:19 +0000 |
---|---|---|
committer | evan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2011-02-04 22:31:19 +0000 |
commit | ed96b47040fe4debcfb6ae7f15c79252519c08dd (patch) | |
tree | 44e61eeeb618a46898c11c03da1baf9e68be7dab | |
parent | c28834f61f07d7aebc54b82060bed29c5a1cf1d4 (diff) | |
download | chromium_src-ed96b47040fe4debcfb6ae7f15c79252519c08dd.zip chromium_src-ed96b47040fe4debcfb6ae7f15c79252519c08dd.tar.gz chromium_src-ed96b47040fe4debcfb6ae7f15c79252519c08dd.tar.bz2 |
Remove a ToWStringHack() from Gears code.
This code is Windows-specific and on the chopping block anyway.
BUG=69467
Review URL: http://codereview.chromium.org/6410090
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@73856 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | chrome/browser/chrome_plugin_host.cc | 10 |
1 files changed, 8 insertions, 2 deletions
diff --git a/chrome/browser/chrome_plugin_host.cc b/chrome/browser/chrome_plugin_host.cc index fc7b9ce..6c83a13 100644 --- a/chrome/browser/chrome_plugin_host.cc +++ b/chrome/browser/chrome_plugin_host.cc @@ -464,8 +464,14 @@ int STDCALL CPB_GetBrowsingContextInfo( if (!service) return CPERR_FAILURE; FilePath path = service->GetChromePluginDataDir(); - std::string retval = WideToUTF8( - path.Append(chrome::kChromePluginDataDirname).ToWStringHack()); + // This is wrong -- we can't in general stuff a path through a std::string. + // But this code is Gears-specific, so Windows-only anyway for now. + std::string retval; +#if defined(OS_WIN) + retval = WideToUTF8(path.Append(chrome::kChromePluginDataDirname).value()); +#else + NOTREACHED(); +#endif *static_cast<char**>(buf) = CPB_StringDup(CPB_Alloc, retval); return CPERR_SUCCESS; } |