diff --git a/libc/stdio/fgets_unlocked.c b/libc/stdio/fgets_unlocked.c index b910fbc34..411df1ee3 100644 --- a/libc/stdio/fgets_unlocked.c +++ b/libc/stdio/fgets_unlocked.c @@ -55,11 +55,7 @@ char *fgets_unlocked(char *s, int size, FILE *f) { if (t) break; } else { if ((c = fgetc_unlocked(f)) == -1) { - if (ferror_unlocked(f) == EINTR) { - continue; - } else { - break; - } + break; } *p++ = c & 255; if (c == '\n') break;