[Python-checkins] cpython (3.3): Issue #15835: Define PATH_MAX on HP-UX.
stefan.krah
python-checkins at python.org
Mon Nov 12 20:37:09 CET 2012
http://hg.python.org/cpython/rev/5db6d9ddf6e8
changeset: 80406:5db6d9ddf6e8
branch: 3.3
parent: 80403:6017f09ead53
user: Stefan Krah <skrah at bytereef.org>
date: Mon Nov 12 20:14:36 2012 +0100
summary:
Issue #15835: Define PATH_MAX on HP-UX.
files:
Include/osdefs.h | 8 ++++++++
Python/fileutils.c | 1 +
2 files changed, 9 insertions(+), 0 deletions(-)
diff --git a/Include/osdefs.h b/Include/osdefs.h
--- a/Include/osdefs.h
+++ b/Include/osdefs.h
@@ -29,6 +29,14 @@
#endif
/* Max pathname length */
+#ifdef __hpux
+#include <sys/param.h>
+#include <limits.h>
+#ifndef PATH_MAX
+#define PATH_MAX MAXPATHLEN
+#endif
+#endif
+
#ifndef MAXPATHLEN
#if defined(PATH_MAX) && PATH_MAX > 1024
#define MAXPATHLEN PATH_MAX
diff --git a/Python/fileutils.c b/Python/fileutils.c
--- a/Python/fileutils.c
+++ b/Python/fileutils.c
@@ -1,4 +1,5 @@
#include "Python.h"
+#include "osdefs.h"
#ifdef MS_WINDOWS
# include <windows.h>
#endif
--
Repository URL: http://hg.python.org/cpython
More information about the Python-checkins
mailing list