summaryrefslogtreecommitdiffstats
path: root/Modules/posixmodule.c
diff options
context:
space:
mode:
authorVictor Stinner <victor.stinner@gmail.com>2015-09-03 19:32:44 (GMT)
committerVictor Stinner <victor.stinner@gmail.com>2015-09-03 19:32:44 (GMT)
commit5b6917e60d2ffc0a87a6a17c234ba143a480dd82 (patch)
tree3305d0ce1b884a19a51eb8432a608c6d4921b97e /Modules/posixmodule.c
parentfda673d59f80a52589fde119468bac8a0561e67c (diff)
parent528a9ab1f0c93d8dabc2b97b39e7252af7372456 (diff)
downloadcpython-5b6917e60d2ffc0a87a6a17c234ba143a480dd82.zip
cpython-5b6917e60d2ffc0a87a6a17c234ba143a480dd82.tar.gz
cpython-5b6917e60d2ffc0a87a6a17c234ba143a480dd82.tar.bz2
Merge 3.4 (ICC)
Diffstat (limited to 'Modules/posixmodule.c')
-rw-r--r--Modules/posixmodule.c12
1 files changed, 4 insertions, 8 deletions
diff --git a/Modules/posixmodule.c b/Modules/posixmodule.c
index ec8c526..d8bb060 100644
--- a/Modules/posixmodule.c
+++ b/Modules/posixmodule.c
@@ -4560,9 +4560,7 @@ typedef struct {
} \
-#define UTIME_HAVE_DIR_FD (defined(HAVE_FUTIMESAT) || defined(HAVE_UTIMENSAT))
-
-#if UTIME_HAVE_DIR_FD
+#if defined(HAVE_FUTIMESAT) || defined(HAVE_UTIMENSAT)
static int
utime_dir_fd(utime_t *ut, int dir_fd, char *path, int follow_symlinks)
@@ -4588,9 +4586,7 @@ utime_dir_fd(utime_t *ut, int dir_fd, char *path, int follow_symlinks)
#define FUTIMENSAT_DIR_FD_CONVERTER dir_fd_unavailable
#endif
-#define UTIME_HAVE_FD (defined(HAVE_FUTIMES) || defined(HAVE_FUTIMENS))
-
-#if UTIME_HAVE_FD
+#if defined(HAVE_FUTIMES) || defined(HAVE_FUTIMENS)
static int
utime_fd(utime_t *ut, int fd)
@@ -4835,13 +4831,13 @@ os_utime_impl(PyModuleDef *module, path_t *path, PyObject *times,
else
#endif
-#if UTIME_HAVE_DIR_FD
+#if defined(HAVE_FUTIMESAT) || defined(HAVE_UTIMENSAT)
if ((dir_fd != DEFAULT_DIR_FD) || (!follow_symlinks))
result = utime_dir_fd(&utime, dir_fd, path->narrow, follow_symlinks);
else
#endif
-#if UTIME_HAVE_FD
+#if defined(HAVE_FUTIMES) || defined(HAVE_FUTIMENS)
if (path->fd != -1)
result = utime_fd(&utime, path->fd);
else