From a8ed096e8c3962073c785d70528f49f5a1b0a871 Mon Sep 17 00:00:00 2001 From: "thestig@chromium.org" Date: Tue, 19 Jan 2010 23:08:20 +0000 Subject: Linux: Don't propagate $GNOME_DISABLE_CRASH_DIALOG to external apps. BUG=24120 TEST=none Review URL: http://codereview.chromium.org/548071 git-svn-id: svn://svn.chromium.org/chrome/trunk/src@36569 0039d316-1c4b-4281-b951-d872f2087c98 --- chrome/common/platform_util_linux.cc | 9 +++++++++ 1 file changed, 9 insertions(+) diff --git a/chrome/common/platform_util_linux.cc b/chrome/common/platform_util_linux.cc index 3bc99ee..697f307 100644 --- a/chrome/common/platform_util_linux.cc +++ b/chrome/common/platform_util_linux.cc @@ -28,6 +28,15 @@ void XDGOpen(const std::string& path) { // bring up a new terminal if necessary. See "man mailcap". env.push_back(std::make_pair("MM_NOTTTY", "1")); + // In Google Chrome, we do not let GNOME's bug-buddy intercept our crashes. + // However, we do not want this environment variable to propagate to external + // applications. See http://crbug.com/24120 + char* disable_gnome_bug_buddy = getenv("GNOME_DISABLE_CRASH_DIALOG"); + if (disable_gnome_bug_buddy && + disable_gnome_bug_buddy == std::string("SET_BY_GOOGLE_CHROME")) { + env.push_back(std::make_pair("GNOME_DISABLE_CRASH_DIALOG", "")); + } + base::file_handle_mapping_vector no_files; base::ProcessHandle handle; if (base::LaunchApp(argv, env, no_files, false, &handle)) -- cgit v1.1