about summary refs log tree commit diff
path: root/sysdeps/unix/sysv/linux/wordsize-64/fxstatat.c
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/unix/sysv/linux/wordsize-64/fxstatat.c')
-rw-r--r--sysdeps/unix/sysv/linux/wordsize-64/fxstatat.c5
1 files changed, 4 insertions, 1 deletions
diff --git a/sysdeps/unix/sysv/linux/wordsize-64/fxstatat.c b/sysdeps/unix/sysv/linux/wordsize-64/fxstatat.c
index 70e73571f7..d88b10e947 100644
--- a/sysdeps/unix/sysv/linux/wordsize-64/fxstatat.c
+++ b/sysdeps/unix/sysv/linux/wordsize-64/fxstatat.c
@@ -70,7 +70,10 @@ __fxstatat (int vers, int fd, const char *file, struct stat *st, int flag)
     res = INTERNAL_SYSCALL (stat, err, 2, file, CHECK_1 (st));
 
   if (__builtin_expect (INTERNAL_SYSCALL_ERROR_P (res, err), 0))
-    __atfct_seterrno (INTERNAL_SYSCALL_ERRNO (res, err), fd, buf);
+    {
+      __atfct_seterrno (INTERNAL_SYSCALL_ERRNO (res, err), fd, buf);
+      res = -1;
+    }
 
   return res;
 }