aboutsummaryrefslogtreecommitdiff
path: root/gdb
diff options
context:
space:
mode:
Diffstat (limited to 'gdb')
-rw-r--r--gdb/ChangeLog5
-rw-r--r--gdb/utils.c2
2 files changed, 6 insertions, 1 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index a19367f..94c8464 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,10 @@
2013-07-01 Pedro Alves <palves@redhat.com>
+ * utils.c <pathconf/_PC_PATH_MAX use>: Check if _PC_PATH_MAX is
+ defined instead of checking HAVE_UNISTD_H.
+
+2013-07-01 Pedro Alves <palves@redhat.com>
+
Reimport gnulib from scratch.
* gnulib/Makefile.in (aclocal_m4_deps): Remove reference to
import/m4/onceonly.m4.
diff --git a/gdb/utils.c b/gdb/utils.c
index f5c1339..a2015a8 100644
--- a/gdb/utils.c
+++ b/gdb/utils.c
@@ -3179,7 +3179,7 @@ gdb_realpath (const char *filename)
pathconf()) making it impossible to pass a correctly sized buffer
to realpath() (it could always overflow). On those systems, we
skip this. */
-#if defined (HAVE_REALPATH) && defined (HAVE_UNISTD_H) && defined(HAVE_ALLOCA)
+#if defined (HAVE_REALPATH) && defined (_PC_PATH_MAX) && defined(HAVE_ALLOCA)
{
/* Find out the max path size. */
long path_max = pathconf ("/", _PC_PATH_MAX);