diff options
author | John Baldwin <jhb@FreeBSD.org> | 2008-05-02 15:25:07 +0000 |
---|---|---|
committer | John Baldwin <jhb@FreeBSD.org> | 2008-05-02 15:25:07 +0000 |
commit | c17bf9a9a5a3b59e03108b785f6b15070ff25651 (patch) | |
tree | 5e0b10db872b1b2fe5276fd887529303487c71d3 /lib/libc/stdio/feof.c | |
parent | ab9306707af1cb42abff2e9f7bc1f23a17f60892 (diff) | |
download | src-c17bf9a9a5a3b59e03108b785f6b15070ff25651.tar.gz src-c17bf9a9a5a3b59e03108b785f6b15070ff25651.zip |
Next round of stdio changes: Remove all inlining of stdio operations and
move the definition of the type backing FILE (struct __sFILE) into an
internal header.
- Remove macros to inline certain operations from stdio.h. Applications
will now always call the functions instead.
- Move the various foo_unlocked() functions from unlocked.c into foo.c.
This lets some of the inlining macros (e.g. __sfeof()) move into
foo.c.
- Update a few comments.
- struct __sFILE can now go back to using mbstate_t, pthread_t, and
pthread_mutex_t instead of knowing about their private, backing types.
MFC after: 1 month
Reviewed by: kan
Notes
Notes:
svn path=/head/; revision=178721
Diffstat (limited to 'lib/libc/stdio/feof.c')
-rw-r--r-- | lib/libc/stdio/feof.c | 10 |
1 files changed, 9 insertions, 1 deletions
diff --git a/lib/libc/stdio/feof.c b/lib/libc/stdio/feof.c index 996004ff11a0..e997103b6418 100644 --- a/lib/libc/stdio/feof.c +++ b/lib/libc/stdio/feof.c @@ -39,9 +39,10 @@ __FBSDID("$FreeBSD$"); #include "namespace.h" #include <stdio.h> #include "un-namespace.h" +#include "local.h" #include "libc_private.h" -#undef feof +#define __sfeof(p) (((p)->_flags & __SEOF) != 0) int feof(FILE *fp) @@ -53,3 +54,10 @@ feof(FILE *fp) FUNLOCKFILE(fp); return (ret); } + +int +feof_unlocked(FILE *fp) +{ + + return (__sfeof(fp)); +} |