Opened 11 years ago

Closed 11 years ago

#3059 closed bug (fixed)

implement _IO_feof_unlocked and _IO_ferror_unlocked in libio.h [PATCH]

Reported by: kaliber Owned by: axeld
Priority: normal Milestone: R1
Component: System/ Version: R1/pre-alpha1
Keywords: Cc:
Blocked By: Blocking:
Has a Patch: no Platform: All

Description (last modified by korli)

commit 359d499fd541d6eb43b42ac96c16a008e0d436bc
Author: Grzegorz Dabrowski <>
Date:   Sun Nov 2 14:42:36 2008 +0100

    implemented _IO_feof_unlocked and _IO_ferror_unlocked

diff --git a/headers/posix/libio.h b/headers/posix/libio.h
index 83caf1d..f284aec 100644
--- a/headers/posix/libio.h
+++ b/headers/posix/libio.h
@@ -170,9 +170,9 @@ extern "C" {
 extern int _IO_feof(_IO_FILE *stream);
-extern int _IO_feof_unlocked(_IO_FILE *stream);
+#define    _IO_feof_unlocked(__fp) (((__fp)->_flags & _IO_EOF_SEEN) != 0)
 extern int _IO_ferror(_IO_FILE *stream);
-extern int _IO_ferror_unlocked(_IO_FILE *stream);
+#define    _IO_ferror_unlocked(__fp) (((__fp)->_flags & _IO_ERR_SEEN) != 0)
 extern int _IO_putc(int c, _IO_FILE *stream);
 extern int _IO_putc_unlocked(int c, _IO_FILE *stream);
 extern int _IO_getc(_IO_FILE *stream);

Change History (2)

comment:1 by kaliber, 11 years ago

Component: - GeneralSystem/

Please review the patch.

comment:2 by korli, 11 years ago

Description: modified (diff)
Resolution: fixed
Status: newclosed

Applied in hrev30861.

Note: See TracTickets for help on using tickets.