]> granicus.if.org Git - python/commitdiff
Jack Jansen, Mac patch:
authorGuido van Rossum <guido@python.org>
Sat, 1 Jul 2000 01:08:11 +0000 (01:08 +0000)
committerGuido van Rossum <guido@python.org>
Sat, 1 Jul 2000 01:08:11 +0000 (01:08 +0000)
If we have stat.h include it if we don't have sys/stat.h

Python/getmtime.c

index 55ec5a3b635c906301eba80e5009d8d3c3101c0b..80fe7b522556ed9afa2a603e0d284739eb5824ef 100644 (file)
@@ -16,8 +16,14 @@ redistribution of this file, and for a DISCLAIMER OF ALL WARRANTIES.
 #include "config.h"
 
 #include <stdio.h>
+#ifndef DONT_HAVE_SYS_TYPES_H
 #include <sys/types.h>
+#endif
+#ifndef DONT_HAVE_SYS_STAT_H
 #include <sys/stat.h>
+#elif defined(HAVE_STAT_H)
+#include <stat.h>
+#endif
 
 time_t
 PyOS_GetLastModificationTime(path, fp)