[Python-checkins] cpython (merge 3.2 -> default): bugfix for *BSD platforms. (oops messed up #define)

gregory.p.smith python-checkins at python.org
Sun Jan 22 00:21:32 CET 2012


http://hg.python.org/cpython/rev/665b748ee4c1
changeset:   74570:665b748ee4c1
parent:      74569:e52d81e0c750
parent:      74568:5be3dadd2eef
user:        Gregory P. Smith <greg at krypto.org>
date:        Sat Jan 21 15:20:37 2012 -0800
summary:
  bugfix for *BSD platforms. (oops messed up #define)

files:
  Modules/_posixsubprocess.c |  6 ++----
  1 files changed, 2 insertions(+), 4 deletions(-)


diff --git a/Modules/_posixsubprocess.c b/Modules/_posixsubprocess.c
--- a/Modules/_posixsubprocess.c
+++ b/Modules/_posixsubprocess.c
@@ -21,10 +21,8 @@
 # define dirent dirent64
 # if !defined(HAVE_DIRFD)
 /* Some versions of Solaris lack dirfd(). */
-#  define DIRFD(dirp) ((dirp)->dd_fd)
+#  define dirfd(dirp) ((dirp)->dd_fd)
 #  define HAVE_DIRFD
-# else
-#  define DIRFD(dirp) (dirfd(dirp))
 # endif
 #endif
 
@@ -250,7 +248,7 @@
     } else {
         struct dirent *dir_entry;
 #ifdef HAVE_DIRFD
-        int fd_used_by_opendir = DIRFD(proc_fd_dir);
+        int fd_used_by_opendir = dirfd(proc_fd_dir);
 #else
         int fd_used_by_opendir = start_fd - 1;
 #endif

-- 
Repository URL: http://hg.python.org/cpython


More information about the Python-checkins mailing list