OSDN Git Service

* shortcut.c: Change symlink condition.
authorcorinna <corinna>
Sun, 25 Feb 2001 09:19:35 +0000 (09:19 +0000)
committercorinna <corinna>
Sun, 25 Feb 2001 09:19:35 +0000 (09:19 +0000)
winsup/cygwin/ChangeLog
winsup/cygwin/shortcut.c

index 5c69aee..ca0d899 100644 (file)
@@ -1,3 +1,7 @@
+Sun Feb 25 10:18:00 2001  Corinna Vinschen <corinna@vinschen.de>
+
+       * shortcut.c: Change symlink condition.
+
 Fri Feb 23 10:42:00 2001  Corinna Vinschen <corinna@vinschen.de>
 
        * mmap.cc (fhandler_disk_file::mmap): Use `addr' correctly.
index 87db49a..5104abe 100644 (file)
@@ -15,6 +15,7 @@ details. */
 #include <ctype.h>
 #include <sys/types.h>
 #include <sys/mount.h>
+#include <sys/strace.h>
 #include <errno.h>
 #include "shortcut.h"
 
@@ -125,9 +126,9 @@ check_shortcut (const char *path, DWORD fileattr, HANDLE h,
       if (FAILED(hres))
        goto close_it;
     }
-  /* It's a symlink.  */
-  *pflags = PATH_SYMLINK;
   res = strlen (contents);
+  if (res) /* It's a symlink.  */
+    *pflags = PATH_SYMLINK;
 
 close_it:
   /* Release the pointer to IPersistFile. */