cleanup based on comments from martine
authorDavid Hill <dhill@conformal.com>
Sat, 29 Jun 2013 23:16:51 +0000 (19:16 -0400)
committerDavid Hill <dhill@conformal.com>
Sat, 29 Jun 2013 23:16:51 +0000 (19:16 -0400)
configure.py
platform_helper.py
src/subprocess-posix.cc
src/subprocess_test.cc

index 6b6b3d0..c838392 100755 (executable)
@@ -48,7 +48,7 @@ parser.add_option('--with-python', metavar='EXE',
                   help='use EXE as the Python interpreter',
                   default=os.path.basename(sys.executable))
 parser.add_option('--force-pselect', action='store_true',
-                  help="ppoll() is used by default on Linux, OpenBSD and Bitrig, but older versions might need to use pselect instead",)
+                  help="ppoll() is used by default where available, but some platforms may need to use pselect instead",)
 (options, args) = parser.parse_args()
 if args:
     print('ERROR: extra unparsed command-line arguments:', args)
index e040246..e615660 100644 (file)
@@ -73,4 +73,4 @@ class Platform( object ):
         return self._platform == 'sunos5'
 
     def is_bitrig(self):
-       return self._platform == 'bitrig'
+        return self._platform == 'bitrig'
index ae010c9..cd22aa9 100644 (file)
@@ -41,7 +41,7 @@ bool Subprocess::Start(SubprocessSet* set, const string& command) {
     Fatal("pipe: %s", strerror(errno));
   fd_ = output_pipe[0];
 #if !defined(USE_PPOLL)
-  // On Linux, OpenBSD and Bitrig, we use ppoll in DoWork(); elsewhere we use pselect
+  // If available, we use ppoll in DoWork(); otherwise we use pselect
   // and so must avoid overly-large FDs.
   if (fd_ >= static_cast<int>(FD_SETSIZE))
     Fatal("pipe: %s", strerror(EMFILE));
index 7e98cad..9b903c8 100644 (file)
@@ -152,7 +152,7 @@ TEST_F(SubprocessTest, SetWithMulti) {
 
 // OS X's process limit is less than 1025 by default
 // (|sysctl kern.maxprocperuid| is 709 on 10.7 and 10.8 and less prior to that).
-#if defined(linux) || defined(__OpenBSD__) || defined(__Bitrig__)
+if !defined(__APPLE__)
 TEST_F(SubprocessTest, SetWithLots) {
   // Arbitrary big number; needs to be over 1024 to confirm we're no longer
   // hostage to pselect.