summaryrefslogtreecommitdiff
path: root/src/stdio/getc_unlocked.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/stdio/getc_unlocked.c')
-rw-r--r--src/stdio/getc_unlocked.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/src/stdio/getc_unlocked.c b/src/stdio/getc_unlocked.c
index 0e68eb79..13c9f867 100644
--- a/src/stdio/getc_unlocked.c
+++ b/src/stdio/getc_unlocked.c
@@ -15,9 +15,7 @@ int getc_unlocked(FILE * stream)
SIGNAL_SAFE(0);
- if (!stream) {
- return EOF;
- }
+ ASSERT_STREAM(stream, 0, OP_INPUT);
if (stream->operation == OP_OUTPUT) {
UNDEFINED("attempted input on stream immediately after output");