Skip to content

Commit 6a4830b

Browse files
authored
Merge pull request #7810 from jepler/read-error-getenv
getenv: treat a read error like eof
2 parents 4517071 + a8bbb21 commit 6a4830b

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

shared-module/os/getenv.c

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -72,7 +72,7 @@ STATIC void close_file(file_arg *active_file) {
7272
// nothing
7373
}
7474
STATIC bool is_eof(file_arg *active_file) {
75-
return f_eof(active_file);
75+
return f_eof(active_file) || f_error(active_file);
7676
}
7777

7878
// Return 0 if there is no next character (EOF).

0 commit comments

Comments
 (0)
pFad - Phonifier reborn

Pfad - The Proxy pFad of © 2024 Garber Painting. All rights reserved.

Note: This service is not intended for secure transactions such as banking, social media, email, or purchasing. Use at your own risk. We assume no liability whatsoever for broken pages.


Alternative Proxies:

Alternative Proxy

pFad Proxy

pFad v3 Proxy

pFad v4 Proxy