summaryrefslogtreecommitdiffstats
path: root/chrome/plugin/chrome_plugin_host.cc
diff options
context:
space:
mode:
authorevan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-02-26 15:11:55 +0000
committerevan@chromium.org <evan@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98>2010-02-26 15:11:55 +0000
commit1840cfcf0da037741761abe2c04f73c354dff17a (patch)
treec4c457c2644b8878c3b6cea341cb152efad86d45 /chrome/plugin/chrome_plugin_host.cc
parent9e8554820f3b972d410ae9a96b837a65ab8d0333 (diff)
downloadchromium_src-1840cfcf0da037741761abe2c04f73c354dff17a.zip
chromium_src-1840cfcf0da037741761abe2c04f73c354dff17a.tar.gz
chromium_src-1840cfcf0da037741761abe2c04f73c354dff17a.tar.bz2
Deprecate file_util::AppendToPath() on non-Windows.
We still have ~150 callers to AppendToPath in our code, but most of them are in the installer and I'm reluctant to fiddle with that code without having an easy way to test it. BUG=24672 Review URL: http://codereview.chromium.org/654013 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@40120 0039d316-1c4b-4281-b951-d872f2087c98
Diffstat (limited to 'chrome/plugin/chrome_plugin_host.cc')
-rw-r--r--chrome/plugin/chrome_plugin_host.cc12
1 files changed, 7 insertions, 5 deletions
diff --git a/chrome/plugin/chrome_plugin_host.cc b/chrome/plugin/chrome_plugin_host.cc
index ab459f4..4561cc4 100644
--- a/chrome/plugin/chrome_plugin_host.cc
+++ b/chrome/plugin/chrome_plugin_host.cc
@@ -422,11 +422,13 @@ int STDCALL CPB_GetBrowsingContextInfo(
if (buf_size < sizeof(char*))
return sizeof(char*);
- std::wstring wretval = CommandLine::ForCurrentProcess()->
- GetSwitchValue(switches::kPluginDataDir);
- DCHECK(!wretval.empty());
- file_util::AppendToPath(&wretval, chrome::kChromePluginDataDirname);
- *static_cast<char**>(buf) = CPB_StringDup(CPB_Alloc, WideToUTF8(wretval));
+ FilePath path = CommandLine::ForCurrentProcess()->
+ GetSwitchValuePath(switches::kPluginDataDir);
+ DCHECK(!path.empty());
+ std::string retval = WideToUTF8(
+ path.Append(chrome::kChromePluginDataDirname).ToWStringHack());
+ *static_cast<char**>(buf) = CPB_StringDup(CPB_Alloc, retval);
+
return CPERR_SUCCESS;
}
case CPBROWSINGCONTEXT_UI_LOCALE_PTR: {