changeset 7744:d2e319ed503d

Test HAVE_READLINK instead of S_ISLNK.
author Bruno Haible <bruno@clisp.org>
date Sat, 23 Dec 2006 15:43:03 +0000
parents 779c18186d57
children b02b3f45b64a
files ChangeLog lib/canonicalize-lgpl.c
diffstat 2 files changed, 9 insertions(+), 2 deletions(-) [+]
line wrap: on
line diff
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,3 +1,10 @@
+2006-12-23  Bruno Haible  <bruno@clisp.org>
+
+	* lib/canonicalize-lgpl.c (__realpath): Test HAVE_READLINK instead of
+	S_ISLNK.
+	Needed because gnulib's sys/stat.h replacement defines S_ISLNK on
+	mingw.
+
 2006-12-22  Bruno Haible  <bruno@clisp.org>
 
 	* lib/copy-file.c: Include acl.h.
--- a/lib/canonicalize-lgpl.c
+++ b/lib/canonicalize-lgpl.c
@@ -101,7 +101,7 @@
   char *rpath, *dest, *extra_buf = NULL;
   const char *start, *end, *rpath_limit;
   long int path_max;
-#ifdef S_ISLNK
+#if HAVE_READLINK
   int num_links = 0;
 #endif
 
@@ -231,7 +231,7 @@
 #endif
 	    goto error;
 
-#ifdef S_ISLNK
+#if HAVE_READLINK
 	  if (S_ISLNK (st.st_mode))
 	    {
 	      char *buf;