about summary refs log tree commit diff
path: root/io/ftw.c
diff options
context:
space:
mode:
Diffstat (limited to 'io/ftw.c')
-rw-r--r--io/ftw.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/io/ftw.c b/io/ftw.c
index eceb4040d0..26dd77fafa 100644
--- a/io/ftw.c
+++ b/io/ftw.c
@@ -594,7 +594,7 @@ ftw_startup (const char *dir, int is_nftw, void *func, int descriptors,
 	{
 	  if (!(flags & FTW_PHYS)
 	      && errno == ENOENT
-	      && LXSTAT (_STAT_VER, dir, &st) == 0
+	      && LXSTAT (_STAT_VER, name, &st) == 0
 	      && S_ISLNK (st.st_mode))
 	    result = (*data.func) (data.dirbuf, &st, data.cvt_arr[FTW_SLN],
 				   &data.ftw);