Index: base/process/launch_posix.cc |
diff --git a/base/process/launch_posix.cc b/base/process/launch_posix.cc |
index 2184051552ddb708feaba23fa70d3b3f3837cd0d..7550a36f521440e0189603846d5d10f1bd4ed413 100644 |
--- a/base/process/launch_posix.cc |
+++ b/base/process/launch_posix.cc |
@@ -44,7 +44,7 @@ |
#include "base/threading/thread_restrictions.h" |
#include "build/build_config.h" |
-#if defined(OS_LINUX) |
+#if defined(OS_LINUX) || defined(OS_AIX) |
#include <sys/prctl.h> |
#endif |
@@ -113,7 +113,7 @@ sigset_t SetSignalMask(const sigset_t& new_sigmask) { |
return old_sigmask; |
} |
-#if !defined(OS_LINUX) || \ |
+#if (!defined(OS_LINUX) && !defined(OS_AIX)) || \ |
(!defined(__i386__) && !defined(__x86_64__) && !defined(__arm__)) |
void ResetChildSignalHandlersToDefaults() { |
// The previous signal handlers are likely to be meaningless in the child's |
@@ -211,7 +211,7 @@ struct ScopedDIRClose { |
// Automatically closes |DIR*|s. |
typedef std::unique_ptr<DIR, ScopedDIRClose> ScopedDIR; |
-#if defined(OS_LINUX) |
+#if defined(OS_LINUX) || defined(OS_AIX) |
static const char kFDDir[] = "/proc/self/fd"; |
#elif defined(OS_MACOSX) |
static const char kFDDir[] = "/dev/fd"; |
@@ -341,7 +341,7 @@ Process LaunchProcess(const std::vector<std::string>& argv, |
} |
pid_t pid; |
-#if defined(OS_LINUX) |
+#if defined(OS_LINUX) || defined(OS_AIX) |
if (options.clone_flags) { |
// Signal handling in this function assumes the creation of a new |
// process, so we check that a thread is not being created by mistake |
@@ -476,7 +476,7 @@ Process LaunchProcess(const std::vector<std::string>& argv, |
// Set NO_NEW_PRIVS by default. Since NO_NEW_PRIVS only exists in kernel |
// 3.5+, do not check the return value of prctl here. |
-#if defined(OS_LINUX) |
+#if defined(OS_LINUX) || defined(OS_AIX) |
#ifndef PR_SET_NO_NEW_PRIVS |
#define PR_SET_NO_NEW_PRIVS 38 |
#endif |
@@ -681,7 +681,7 @@ bool GetAppOutputWithExitCode(const CommandLine& cl, |
#endif // !defined(OS_NACL_NONSFI) |
-#if defined(OS_LINUX) || defined(OS_NACL_NONSFI) |
+#if defined(OS_LINUX) || defined(OS_NACL_NONSFI) || defined(OS_AIX) |
namespace { |
bool IsRunningOnValgrind() { |