about summary refs log tree commit diff
path: root/sysdeps/unix/getlogin.c
diff options
context:
space:
mode:
Diffstat (limited to 'sysdeps/unix/getlogin.c')
-rw-r--r--sysdeps/unix/getlogin.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/sysdeps/unix/getlogin.c b/sysdeps/unix/getlogin.c
index e23ffa46f5..ef985f2d2f 100644
--- a/sysdeps/unix/getlogin.c
+++ b/sysdeps/unix/getlogin.c
@@ -58,7 +58,7 @@ getlogin (void)
     {
       if (errno == ESRCH)
 	/* The caller expects ENOENT if nothing is found.  */
-	errno = ENOENT;
+	__set_errno (ENOENT);
       result = NULL;
     }
   else