diff options
author | mdm@chromium.org <mdm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-07-22 18:21:27 +0000 |
---|---|---|
committer | mdm@chromium.org <mdm@chromium.org@0039d316-1c4b-4281-b951-d872f2087c98> | 2009-07-22 18:21:27 +0000 |
commit | 7a97d29f07bebe8cc2ba52ec9dbeded128a95c21 (patch) | |
tree | cd1cb5e36b42d7f8b81ce96e7d3693c4492d98b1 | |
parent | 1d379a14439d1ba1753a3fbe91d3fd4bcd6e21ba (diff) | |
download | chromium_src-7a97d29f07bebe8cc2ba52ec9dbeded128a95c21.zip chromium_src-7a97d29f07bebe8cc2ba52ec9dbeded128a95c21.tar.gz chromium_src-7a97d29f07bebe8cc2ba52ec9dbeded128a95c21.tar.bz2 |
Linux/Mac: Use _exit() instead of exit() in the child after fork() in failure conditions.
BUG=17329
TEST=none
Review URL: http://codereview.chromium.org/159201
git-svn-id: svn://svn.chromium.org/chrome/trunk/src@21294 0039d316-1c4b-4281-b951-d872f2087c98
-rw-r--r-- | base/process_util_posix.cc | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/base/process_util_posix.cc b/base/process_util_posix.cc index eb3b814..a03b45c 100644 --- a/base/process_util_posix.cc +++ b/base/process_util_posix.cc @@ -443,7 +443,7 @@ bool GetAppOutput(const CommandLine& cl, std::string* output) { { int dev_null = open("/dev/null", O_WRONLY); if (dev_null < 0) - exit(127); + _exit(127); InjectiveMultimap fd_shuffle; fd_shuffle.push_back(InjectionArc(pipe_fd[1], STDOUT_FILENO, true)); @@ -451,7 +451,7 @@ bool GetAppOutput(const CommandLine& cl, std::string* output) { fd_shuffle.push_back(InjectionArc(dev_null, STDIN_FILENO, true)); if (!ShuffleFileDescriptors(fd_shuffle)) - exit(127); + _exit(127); CloseSuperfluousFds(fd_shuffle); @@ -461,7 +461,7 @@ bool GetAppOutput(const CommandLine& cl, std::string* output) { argv_cstr[i] = const_cast<char*>(argv[i].c_str()); argv_cstr[argv.size()] = NULL; execvp(argv_cstr[0], argv_cstr.get()); - exit(127); + _exit(127); } default: // parent { |