#undef getcwd before including system headers.

This avoid a build failure on IRIX 6.5.  Reported by Nelson Beebe.
This commit is contained in:
Jim Meyering committed 2003-03-06 22:23:26 +00:00
1 parent 08e9a37430
commit b4e7a90ce6
1 file changed
+4 -8
+4 -8
View File
@@ -19,6 +19,10 @@
#include <config.h>
/* Undefine getcwd here so any prototype is not redefined to be a
prototype for rpl_getcwd. */
#undef getcwd
#include <stdlib.h>
#include <string.h>
@@ -32,14 +36,6 @@ extern int errno;
#include "pathmax.h"
#include "same.h"
/* Undefine getcwd here so any prototype is not redefined to be a
prototype for rpl_getcwd. */
#undef getcwd
#if !HAVE_DECL_GETCWD
extern char *getcwd (char *, size_t);
#endif
/* Guess high, because that makes the test below more conservative.
But this is a kludge, because we should really use
pathconf (".", _PC_NAME_MAX). But it's probably not worth the cost. */