]> git.ipfire.org Git - thirdparty/glibc.git/blobdiff - shadow/fgetspent_r.c
elf: Refuse to dlopen PIE objects [BZ #24323]
[thirdparty/glibc.git] / shadow / fgetspent_r.c
index d63ce2e430bc99876c41c7b8f492a142f65141cd..e217647cb3482b906d44b5772e8cdbd4160dde81 100644 (file)
@@ -1,4 +1,4 @@
-/* Copyright (C) 1996-2016 Free Software Foundation, Inc.
+/* Copyright (C) 1996-2019 Free Software Foundation, Inc.
    This file is part of the GNU C Library.
 
    The GNU C Library is free software; you can redistribute it and/or
@@ -64,10 +64,10 @@ __fgetspent_r (FILE *stream, struct spwd *resbuf, char *buffer, size_t buflen,
       /* Skip leading blanks.  */
       while (isspace (*p))
        ++p;
-    } while (*p == '\0' || *p == '#' ||        /* Ignore empty and comment lines.  */
+    } while (*p == '\0' || *p == '#' /* Ignore empty and comment lines.  */
             /* Parse the line.  If it is invalid, loop to
                get the next line of the file to parse.  */
-            ! parse_line (buffer, (void *) resbuf, NULL, 0, &errno));
+            || ! parse_line (buffer, (void *) resbuf, NULL, 0, &errno));
 
   funlockfile (stream);