Date: Thu, 14 Jun 2012 15:06:31 GMT From: svn-freebsd-gecko@chruetertee.ch To: freebsd-gecko@freebsd.org Subject: [SVN-Commit] r757 - in branches/experimental/www: firefox-beta/files firefox-esr/files firefox-nightly/files firefox/files libxul/files Message-ID: <201206141506.q5EF6VrH073265@trillian.chruetertee.ch>
next in thread | raw e-mail | index | archive | help
Author: jbeich Date: Thu Jun 14 15:06:30 2012 New Revision: 757 Log: use shorter fix, taken from example in http://wiki.freebsd.org/NewC++Stack Added: branches/experimental/www/firefox-beta/files/patch-dom-plugins-ipc-PluginMessageUtils.cpp branches/experimental/www/firefox-esr/files/patch-dom-plugins-ipc-PluginMessageUtils.cpp branches/experimental/www/firefox-nightly/files/patch-dom-plugins-ipc-PluginMessageUtils.cpp branches/experimental/www/firefox/files/patch-dom-plugins-ipc-PluginMessageUtils.cpp branches/experimental/www/libxul/files/patch-dom-plugins-ipc-PluginMessageUtils.cpp Deleted: branches/experimental/www/firefox-beta/files/patch-libcxx-revert-bug519601 branches/experimental/www/firefox-esr/files/patch-libcxx-revert-bug519601 branches/experimental/www/firefox-nightly/files/patch-libcxx-revert-bug519601 branches/experimental/www/firefox/files/patch-libcxx-revert-bug519601 branches/experimental/www/libxul/files/patch-libcxx-revert-bug519601 Added: branches/experimental/www/firefox-beta/files/patch-dom-plugins-ipc-PluginMessageUtils.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ branches/experimental/www/firefox-beta/files/patch-dom-plugins-ipc-PluginMessageUtils.cpp Thu Jun 14 15:06:30 2012 (r757) @@ -0,0 +1,11 @@ +--- dom/plugins/ipc/PluginMessageUtils.cpp~ ++++ dom/plugins/ipc/PluginMessageUtils.cpp +@@ -94,7 +94,7 @@ ReplaceAll(const string& haystack, const + i += with.length(); + } + +- return munged; ++ return munged.c_str(); + } + #endif + Deleted: branches/experimental/www/firefox-beta/files/patch-libcxx-revert-bug519601 ============================================================================== --- branches/experimental/www/firefox-beta/files/patch-libcxx-revert-bug519601 Thu Jun 14 15:06:30 2012 (r756) +++ /dev/null 00:00:00 1970 (deleted) @@ -1,116 +0,0 @@ -changeset: 40752:cc5ace5d6ade -user: Karl Tomlinson <karlt@mozbugz.karlt.net> and Chris Jones <jones.chris.g@gmail.com> -date: Wed Apr 14 02:04:52 2010 -0500 -summary: Bug 519601: s/netscape/netsc@pe/ for plugin dso paths passed on the command line on linux. r=karlt - -diff --git a/dom/plugins/ipc/PluginMessageUtils.cpp b/dom/plugins/ipc/PluginMessageUtils.cpp ---- dom/plugins/ipc/PluginMessageUtils.cpp -+++ dom/plugins/ipc/PluginMessageUtils.cpp -@@ -13,8 +13,6 @@ - #include "PluginScriptableObjectParent.h" - #include "PluginScriptableObjectChild.h" - --using std::string; -- - using mozilla::ipc::RPCChannel; - - namespace { -@@ -114,42 +112,6 @@ MediateRace(const RPCChannel::Message& p - } - } - --static string --ReplaceAll(const string& haystack, const string& needle, const string& with) --{ -- string munged = haystack; -- string::size_type i = 0; -- -- while (string::npos != (i = munged.find(needle, i))) { -- munged.replace(i, needle.length(), with); -- i += with.length(); -- } -- -- return munged; --} -- --string --MungePluginDsoPath(const string& path) --{ --#if defined(OS_LINUX) -- // https://bugzilla.mozilla.org/show_bug.cgi?id=519601 -- return ReplaceAll(path, "netscape", "netsc@pe"); --#else -- return path; --#endif --} -- --string --UnmungePluginDsoPath(const string& munged) --{ --#if defined(OS_LINUX) -- return ReplaceAll(munged, "netsc@pe", "netscape"); --#else -- return munged; --#endif --} -- -- - PRLogModuleInfo* gPluginLog = PR_NewLogModule("IPCPlugins"); - - void -diff --git a/dom/plugins/ipc/PluginMessageUtils.h b/dom/plugins/ipc/PluginMessageUtils.h ---- dom/plugins/ipc/PluginMessageUtils.h -+++ dom/plugins/ipc/PluginMessageUtils.h -@@ -48,11 +48,6 @@ mozilla::ipc::RPCChannel::RacyRPCPolicy - MediateRace(const mozilla::ipc::RPCChannel::Message& parent, - const mozilla::ipc::RPCChannel::Message& child); - --std::string --MungePluginDsoPath(const std::string& path); --std::string --UnmungePluginDsoPath(const std::string& munged); -- - extern PRLogModuleInfo* gPluginLog; - - const uint32_t kAllowAsyncDrawing = 0x1; -diff --git a/dom/plugins/ipc/PluginProcessChild.cpp b/dom/plugins/ipc/PluginProcessChild.cpp ---- dom/plugins/ipc/PluginProcessChild.cpp -+++ dom/plugins/ipc/PluginProcessChild.cpp -@@ -95,7 +95,7 @@ PluginProcessChild::Init() - std::vector<std::string> values = CommandLine::ForCurrentProcess()->argv(); - NS_ABORT_IF_FALSE(values.size() >= 2, "not enough args"); - -- pluginFilename = UnmungePluginDsoPath(values[1]); -+ pluginFilename = values[1]; - - #elif defined(OS_WIN) - std::vector<std::wstring> values = -diff --git a/dom/plugins/ipc/PluginProcessParent.cpp b/dom/plugins/ipc/PluginProcessParent.cpp ---- dom/plugins/ipc/PluginProcessParent.cpp -+++ dom/plugins/ipc/PluginProcessParent.cpp -@@ -10,10 +10,6 @@ - #include "base/process_util.h" - - #include "mozilla/ipc/BrowserProcessSubThread.h" --#include "mozilla/plugins/PluginMessageUtils.h" -- --using std::vector; --using std::string; - - using mozilla::ipc::BrowserProcessSubThread; - using mozilla::ipc::GeckoChildProcessHost; -@@ -73,8 +69,12 @@ PluginProcessParent::Launch(PRInt32 time - } - } - -- vector<string> args; -- args.push_back(MungePluginDsoPath(mPluginFilePath)); -+ std::vector<std::string> args; -+#if defined(XP_WIN) -+ args.push_back("\""+ mPluginFilePath +"\""); -+#else -+ args.push_back(mPluginFilePath); -+#endif - return SyncLaunch(args, timeoutMs, selectedArchitecture); - } - Added: branches/experimental/www/firefox-esr/files/patch-dom-plugins-ipc-PluginMessageUtils.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ branches/experimental/www/firefox-esr/files/patch-dom-plugins-ipc-PluginMessageUtils.cpp Thu Jun 14 15:06:30 2012 (r757) @@ -0,0 +1,11 @@ +--- dom/plugins/ipc/PluginMessageUtils.cpp~ ++++ dom/plugins/ipc/PluginMessageUtils.cpp +@@ -94,7 +94,7 @@ ReplaceAll(const string& haystack, const + i += with.length(); + } + +- return munged; ++ return munged.c_str(); + } + #endif + Deleted: branches/experimental/www/firefox-esr/files/patch-libcxx-revert-bug519601 ============================================================================== --- branches/experimental/www/firefox-esr/files/patch-libcxx-revert-bug519601 Thu Jun 14 15:06:30 2012 (r756) +++ /dev/null 00:00:00 1970 (deleted) @@ -1,116 +0,0 @@ -changeset: 40752:cc5ace5d6ade -user: Karl Tomlinson <karlt@mozbugz.karlt.net> and Chris Jones <jones.chris.g@gmail.com> -date: Wed Apr 14 02:04:52 2010 -0500 -summary: Bug 519601: s/netscape/netsc@pe/ for plugin dso paths passed on the command line on linux. r=karlt - -diff --git a/dom/plugins/ipc/PluginMessageUtils.cpp b/dom/plugins/ipc/PluginMessageUtils.cpp ---- dom/plugins/ipc/PluginMessageUtils.cpp -+++ dom/plugins/ipc/PluginMessageUtils.cpp -@@ -13,8 +13,6 @@ - #include "PluginScriptableObjectParent.h" - #include "PluginScriptableObjectChild.h" - --using std::string; -- - using mozilla::ipc::RPCChannel; - - namespace { -@@ -114,42 +112,6 @@ MediateRace(const RPCChannel::Message& p - } - } - --static string --ReplaceAll(const string& haystack, const string& needle, const string& with) --{ -- string munged = haystack; -- string::size_type i = 0; -- -- while (string::npos != (i = munged.find(needle, i))) { -- munged.replace(i, needle.length(), with); -- i += with.length(); -- } -- -- return munged; --} -- --string --MungePluginDsoPath(const string& path) --{ --#if defined(OS_LINUX) -- // https://bugzilla.mozilla.org/show_bug.cgi?id=519601 -- return ReplaceAll(path, "netscape", "netsc@pe"); --#else -- return path; --#endif --} -- --string --UnmungePluginDsoPath(const string& munged) --{ --#if defined(OS_LINUX) -- return ReplaceAll(munged, "netsc@pe", "netscape"); --#else -- return munged; --#endif --} -- -- - PRLogModuleInfo* gPluginLog = PR_NewLogModule("IPCPlugins"); - - void -diff --git a/dom/plugins/ipc/PluginMessageUtils.h b/dom/plugins/ipc/PluginMessageUtils.h ---- dom/plugins/ipc/PluginMessageUtils.h -+++ dom/plugins/ipc/PluginMessageUtils.h -@@ -48,11 +48,6 @@ mozilla::ipc::RPCChannel::RacyRPCPolicy - MediateRace(const mozilla::ipc::RPCChannel::Message& parent, - const mozilla::ipc::RPCChannel::Message& child); - --std::string --MungePluginDsoPath(const std::string& path); --std::string --UnmungePluginDsoPath(const std::string& munged); -- - extern PRLogModuleInfo* gPluginLog; - - const uint32_t kAllowAsyncDrawing = 0x1; -diff --git a/dom/plugins/ipc/PluginProcessChild.cpp b/dom/plugins/ipc/PluginProcessChild.cpp ---- dom/plugins/ipc/PluginProcessChild.cpp -+++ dom/plugins/ipc/PluginProcessChild.cpp -@@ -95,7 +95,7 @@ PluginProcessChild::Init() - std::vector<std::string> values = CommandLine::ForCurrentProcess()->argv(); - NS_ABORT_IF_FALSE(values.size() >= 2, "not enough args"); - -- pluginFilename = UnmungePluginDsoPath(values[1]); -+ pluginFilename = values[1]; - - #elif defined(OS_WIN) - std::vector<std::wstring> values = -diff --git a/dom/plugins/ipc/PluginProcessParent.cpp b/dom/plugins/ipc/PluginProcessParent.cpp ---- dom/plugins/ipc/PluginProcessParent.cpp -+++ dom/plugins/ipc/PluginProcessParent.cpp -@@ -10,10 +10,6 @@ - #include "base/process_util.h" - - #include "mozilla/ipc/BrowserProcessSubThread.h" --#include "mozilla/plugins/PluginMessageUtils.h" -- --using std::vector; --using std::string; - - using mozilla::ipc::BrowserProcessSubThread; - using mozilla::ipc::GeckoChildProcessHost; -@@ -73,8 +69,12 @@ PluginProcessParent::Launch(PRInt32 time - } - } - -- vector<string> args; -- args.push_back(MungePluginDsoPath(mPluginFilePath)); -+ std::vector<std::string> args; -+#if defined(XP_WIN) -+ args.push_back("\""+ mPluginFilePath +"\""); -+#else -+ args.push_back(mPluginFilePath); -+#endif - return SyncLaunch(args, timeoutMs, selectedArchitecture); - } - Added: branches/experimental/www/firefox-nightly/files/patch-dom-plugins-ipc-PluginMessageUtils.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ branches/experimental/www/firefox-nightly/files/patch-dom-plugins-ipc-PluginMessageUtils.cpp Thu Jun 14 15:06:30 2012 (r757) @@ -0,0 +1,11 @@ +--- dom/plugins/ipc/PluginMessageUtils.cpp~ ++++ dom/plugins/ipc/PluginMessageUtils.cpp +@@ -94,7 +94,7 @@ ReplaceAll(const string& haystack, const + i += with.length(); + } + +- return munged; ++ return munged.c_str(); + } + #endif + Deleted: branches/experimental/www/firefox-nightly/files/patch-libcxx-revert-bug519601 ============================================================================== --- branches/experimental/www/firefox-nightly/files/patch-libcxx-revert-bug519601 Thu Jun 14 15:06:30 2012 (r756) +++ /dev/null 00:00:00 1970 (deleted) @@ -1,118 +0,0 @@ -changeset: 40752:cc5ace5d6ade -user: Karl Tomlinson <karlt@mozbugz.karlt.net> and Chris Jones <jones.chris.g@gmail.com> -date: Wed Apr 14 02:04:52 2010 -0500 -summary: Bug 519601: s/netscape/netsc@pe/ for plugin dso paths passed on the command line on linux. r=karlt - -diff --git a/dom/plugins/ipc/PluginMessageUtils.cpp b/dom/plugins/ipc/PluginMessageUtils.cpp ---- dom/plugins/ipc/PluginMessageUtils.cpp -+++ dom/plugins/ipc/PluginMessageUtils.cpp -@@ -13,8 +13,6 @@ - #include "PluginScriptableObjectParent.h" - #include "PluginScriptableObjectChild.h" - --using std::string; -- - using mozilla::ipc::RPCChannel; - - namespace { -@@ -82,44 +80,6 @@ MediateRace(const RPCChannel::Message& p - } - } - --#if defined(OS_LINUX) --static string --ReplaceAll(const string& haystack, const string& needle, const string& with) --{ -- string munged = haystack; -- string::size_type i = 0; -- -- while (string::npos != (i = munged.find(needle, i))) { -- munged.replace(i, needle.length(), with); -- i += with.length(); -- } -- -- return munged; --} --#endif -- --string --MungePluginDsoPath(const string& path) --{ --#if defined(OS_LINUX) -- // https://bugzilla.mozilla.org/show_bug.cgi?id=519601 -- return ReplaceAll(path, "netscape", "netsc@pe"); --#else -- return path; --#endif --} -- --string --UnmungePluginDsoPath(const string& munged) --{ --#if defined(OS_LINUX) -- return ReplaceAll(munged, "netsc@pe", "netscape"); --#else -- return munged; --#endif --} -- -- - PRLogModuleInfo* gPluginLog = PR_NewLogModule("IPCPlugins"); - - void -diff --git a/dom/plugins/ipc/PluginMessageUtils.h b/dom/plugins/ipc/PluginMessageUtils.h ---- dom/plugins/ipc/PluginMessageUtils.h -+++ dom/plugins/ipc/PluginMessageUtils.h -@@ -48,11 +48,6 @@ mozilla::ipc::RPCChannel::RacyRPCPolicy - MediateRace(const mozilla::ipc::RPCChannel::Message& parent, - const mozilla::ipc::RPCChannel::Message& child); - --std::string --MungePluginDsoPath(const std::string& path); --std::string --UnmungePluginDsoPath(const std::string& munged); -- - extern PRLogModuleInfo* gPluginLog; - - const uint32_t kAllowAsyncDrawing = 0x1; -diff --git a/dom/plugins/ipc/PluginProcessChild.cpp b/dom/plugins/ipc/PluginProcessChild.cpp ---- dom/plugins/ipc/PluginProcessChild.cpp -+++ dom/plugins/ipc/PluginProcessChild.cpp -@@ -95,7 +95,7 @@ PluginProcessChild::Init() - std::vector<std::string> values = CommandLine::ForCurrentProcess()->argv(); - NS_ABORT_IF_FALSE(values.size() >= 2, "not enough args"); - -- pluginFilename = UnmungePluginDsoPath(values[1]); -+ pluginFilename = values[1]; - - #elif defined(OS_WIN) - std::vector<std::wstring> values = -diff --git a/dom/plugins/ipc/PluginProcessParent.cpp b/dom/plugins/ipc/PluginProcessParent.cpp ---- dom/plugins/ipc/PluginProcessParent.cpp -+++ dom/plugins/ipc/PluginProcessParent.cpp -@@ -10,10 +10,6 @@ - #include "base/process_util.h" - - #include "mozilla/ipc/BrowserProcessSubThread.h" --#include "mozilla/plugins/PluginMessageUtils.h" -- --using std::vector; --using std::string; - - using mozilla::ipc::BrowserProcessSubThread; - using mozilla::ipc::GeckoChildProcessHost; -@@ -73,8 +69,12 @@ PluginProcessParent::Launch(PRInt32 time - } - } - -- vector<string> args; -- args.push_back(MungePluginDsoPath(mPluginFilePath)); -+ std::vector<std::string> args; -+#if defined(XP_WIN) -+ args.push_back("\""+ mPluginFilePath +"\""); -+#else -+ args.push_back(mPluginFilePath); -+#endif - return SyncLaunch(args, timeoutMs, selectedArchitecture); - } - Added: branches/experimental/www/firefox/files/patch-dom-plugins-ipc-PluginMessageUtils.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ branches/experimental/www/firefox/files/patch-dom-plugins-ipc-PluginMessageUtils.cpp Thu Jun 14 15:06:30 2012 (r757) @@ -0,0 +1,11 @@ +--- dom/plugins/ipc/PluginMessageUtils.cpp~ ++++ dom/plugins/ipc/PluginMessageUtils.cpp +@@ -94,7 +94,7 @@ ReplaceAll(const string& haystack, const + i += with.length(); + } + +- return munged; ++ return munged.c_str(); + } + #endif + Deleted: branches/experimental/www/firefox/files/patch-libcxx-revert-bug519601 ============================================================================== --- branches/experimental/www/firefox/files/patch-libcxx-revert-bug519601 Thu Jun 14 15:06:30 2012 (r756) +++ /dev/null 00:00:00 1970 (deleted) @@ -1,118 +0,0 @@ -changeset: 40752:cc5ace5d6ade -user: Karl Tomlinson <karlt@mozbugz.karlt.net> and Chris Jones <jones.chris.g@gmail.com> -date: Wed Apr 14 02:04:52 2010 -0500 -summary: Bug 519601: s/netscape/netsc@pe/ for plugin dso paths passed on the command line on linux. r=karlt - -diff --git a/dom/plugins/ipc/PluginMessageUtils.cpp b/dom/plugins/ipc/PluginMessageUtils.cpp ---- dom/plugins/ipc/PluginMessageUtils.cpp -+++ dom/plugins/ipc/PluginMessageUtils.cpp -@@ -13,8 +13,6 @@ - #include "PluginScriptableObjectParent.h" - #include "PluginScriptableObjectChild.h" - --using std::string; -- - using mozilla::ipc::RPCChannel; - - namespace { -@@ -82,44 +80,6 @@ MediateRace(const RPCChannel::Message& p - } - } - --#if defined(OS_LINUX) --static string --ReplaceAll(const string& haystack, const string& needle, const string& with) --{ -- string munged = haystack; -- string::size_type i = 0; -- -- while (string::npos != (i = munged.find(needle, i))) { -- munged.replace(i, needle.length(), with); -- i += with.length(); -- } -- -- return munged; --} --#endif -- --string --MungePluginDsoPath(const string& path) --{ --#if defined(OS_LINUX) -- // https://bugzilla.mozilla.org/show_bug.cgi?id=519601 -- return ReplaceAll(path, "netscape", "netsc@pe"); --#else -- return path; --#endif --} -- --string --UnmungePluginDsoPath(const string& munged) --{ --#if defined(OS_LINUX) -- return ReplaceAll(munged, "netsc@pe", "netscape"); --#else -- return munged; --#endif --} -- -- - PRLogModuleInfo* gPluginLog = PR_NewLogModule("IPCPlugins"); - - void -diff --git a/dom/plugins/ipc/PluginMessageUtils.h b/dom/plugins/ipc/PluginMessageUtils.h ---- dom/plugins/ipc/PluginMessageUtils.h -+++ dom/plugins/ipc/PluginMessageUtils.h -@@ -48,11 +48,6 @@ mozilla::ipc::RPCChannel::RacyRPCPolicy - MediateRace(const mozilla::ipc::RPCChannel::Message& parent, - const mozilla::ipc::RPCChannel::Message& child); - --std::string --MungePluginDsoPath(const std::string& path); --std::string --UnmungePluginDsoPath(const std::string& munged); -- - extern PRLogModuleInfo* gPluginLog; - - const uint32_t kAllowAsyncDrawing = 0x1; -diff --git a/dom/plugins/ipc/PluginProcessChild.cpp b/dom/plugins/ipc/PluginProcessChild.cpp ---- dom/plugins/ipc/PluginProcessChild.cpp -+++ dom/plugins/ipc/PluginProcessChild.cpp -@@ -95,7 +95,7 @@ PluginProcessChild::Init() - std::vector<std::string> values = CommandLine::ForCurrentProcess()->argv(); - NS_ABORT_IF_FALSE(values.size() >= 2, "not enough args"); - -- pluginFilename = UnmungePluginDsoPath(values[1]); -+ pluginFilename = values[1]; - - #elif defined(OS_WIN) - std::vector<std::wstring> values = -diff --git a/dom/plugins/ipc/PluginProcessParent.cpp b/dom/plugins/ipc/PluginProcessParent.cpp ---- dom/plugins/ipc/PluginProcessParent.cpp -+++ dom/plugins/ipc/PluginProcessParent.cpp -@@ -10,10 +10,6 @@ - #include "base/process_util.h" - - #include "mozilla/ipc/BrowserProcessSubThread.h" --#include "mozilla/plugins/PluginMessageUtils.h" -- --using std::vector; --using std::string; - - using mozilla::ipc::BrowserProcessSubThread; - using mozilla::ipc::GeckoChildProcessHost; -@@ -73,8 +69,12 @@ PluginProcessParent::Launch(PRInt32 time - } - } - -- vector<string> args; -- args.push_back(MungePluginDsoPath(mPluginFilePath)); -+ std::vector<std::string> args; -+#if defined(XP_WIN) -+ args.push_back("\""+ mPluginFilePath +"\""); -+#else -+ args.push_back(mPluginFilePath); -+#endif - return SyncLaunch(args, timeoutMs, selectedArchitecture); - } - Added: branches/experimental/www/libxul/files/patch-dom-plugins-ipc-PluginMessageUtils.cpp ============================================================================== --- /dev/null 00:00:00 1970 (empty, because file is newly added) +++ branches/experimental/www/libxul/files/patch-dom-plugins-ipc-PluginMessageUtils.cpp Thu Jun 14 15:06:30 2012 (r757) @@ -0,0 +1,11 @@ +--- dom/plugins/ipc/PluginMessageUtils.cpp~ ++++ dom/plugins/ipc/PluginMessageUtils.cpp +@@ -94,7 +94,7 @@ ReplaceAll(const string& haystack, const + i += with.length(); + } + +- return munged; ++ return munged.c_str(); + } + #endif + Deleted: branches/experimental/www/libxul/files/patch-libcxx-revert-bug519601 ============================================================================== --- branches/experimental/www/libxul/files/patch-libcxx-revert-bug519601 Thu Jun 14 15:06:30 2012 (r756) +++ /dev/null 00:00:00 1970 (deleted) @@ -1,116 +0,0 @@ -changeset: 40752:cc5ace5d6ade -user: Karl Tomlinson <karlt@mozbugz.karlt.net> and Chris Jones <jones.chris.g@gmail.com> -date: Wed Apr 14 02:04:52 2010 -0500 -summary: Bug 519601: s/netscape/netsc@pe/ for plugin dso paths passed on the command line on linux. r=karlt - -diff --git a/dom/plugins/ipc/PluginMessageUtils.cpp b/dom/plugins/ipc/PluginMessageUtils.cpp ---- dom/plugins/ipc/PluginMessageUtils.cpp -+++ dom/plugins/ipc/PluginMessageUtils.cpp -@@ -13,8 +13,6 @@ - #include "PluginScriptableObjectParent.h" - #include "PluginScriptableObjectChild.h" - --using std::string; -- - using mozilla::ipc::RPCChannel; - - namespace { -@@ -114,42 +112,6 @@ MediateRace(const RPCChannel::Message& p - } - } - --static string --ReplaceAll(const string& haystack, const string& needle, const string& with) --{ -- string munged = haystack; -- string::size_type i = 0; -- -- while (string::npos != (i = munged.find(needle, i))) { -- munged.replace(i, needle.length(), with); -- i += with.length(); -- } -- -- return munged; --} -- --string --MungePluginDsoPath(const string& path) --{ --#if defined(OS_LINUX) -- // https://bugzilla.mozilla.org/show_bug.cgi?id=519601 -- return ReplaceAll(path, "netscape", "netsc@pe"); --#else -- return path; --#endif --} -- --string --UnmungePluginDsoPath(const string& munged) --{ --#if defined(OS_LINUX) -- return ReplaceAll(munged, "netsc@pe", "netscape"); --#else -- return munged; --#endif --} -- -- - PRLogModuleInfo* gPluginLog = PR_NewLogModule("IPCPlugins"); - - void -diff --git a/dom/plugins/ipc/PluginMessageUtils.h b/dom/plugins/ipc/PluginMessageUtils.h ---- dom/plugins/ipc/PluginMessageUtils.h -+++ dom/plugins/ipc/PluginMessageUtils.h -@@ -48,11 +48,6 @@ mozilla::ipc::RPCChannel::RacyRPCPolicy - MediateRace(const mozilla::ipc::RPCChannel::Message& parent, - const mozilla::ipc::RPCChannel::Message& child); - --std::string --MungePluginDsoPath(const std::string& path); --std::string --UnmungePluginDsoPath(const std::string& munged); -- - extern PRLogModuleInfo* gPluginLog; - - const uint32_t kAllowAsyncDrawing = 0x1; -diff --git a/dom/plugins/ipc/PluginProcessChild.cpp b/dom/plugins/ipc/PluginProcessChild.cpp ---- dom/plugins/ipc/PluginProcessChild.cpp -+++ dom/plugins/ipc/PluginProcessChild.cpp -@@ -95,7 +95,7 @@ PluginProcessChild::Init() - std::vector<std::string> values = CommandLine::ForCurrentProcess()->argv(); - NS_ABORT_IF_FALSE(values.size() >= 2, "not enough args"); - -- pluginFilename = UnmungePluginDsoPath(values[1]); -+ pluginFilename = values[1]; - - #elif defined(OS_WIN) - std::vector<std::wstring> values = -diff --git a/dom/plugins/ipc/PluginProcessParent.cpp b/dom/plugins/ipc/PluginProcessParent.cpp ---- dom/plugins/ipc/PluginProcessParent.cpp -+++ dom/plugins/ipc/PluginProcessParent.cpp -@@ -10,10 +10,6 @@ - #include "base/process_util.h" - - #include "mozilla/ipc/BrowserProcessSubThread.h" --#include "mozilla/plugins/PluginMessageUtils.h" -- --using std::vector; --using std::string; - - using mozilla::ipc::BrowserProcessSubThread; - using mozilla::ipc::GeckoChildProcessHost; -@@ -73,8 +69,12 @@ PluginProcessParent::Launch(PRInt32 time - } - } - -- vector<string> args; -- args.push_back(MungePluginDsoPath(mPluginFilePath)); -+ std::vector<std::string> args; -+#if defined(XP_WIN) -+ args.push_back("\""+ mPluginFilePath +"\""); -+#else -+ args.push_back(mPluginFilePath); -+#endif - return SyncLaunch(args, timeoutMs, selectedArchitecture); - } -
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?201206141506.q5EF6VrH073265>