diff options
author | Gwenolé Beauchesne <gbeauchesne@mandriva.org> | 2003-06-04 18:47:09 +0000 |
---|---|---|
committer | Gwenolé Beauchesne <gbeauchesne@mandriva.org> | 2003-06-04 18:47:09 +0000 |
commit | c46806bf74c2618daa398cb7c3e4b1c47509a105 (patch) | |
tree | 0b429074ffc365e7eba2391cf00d7f4eecf372ab /mdk-stage1/dietlibc/libstdio/fgetc.c | |
parent | 7b14ca284d598e7748f6f7a831389525c84890ba (diff) | |
download | drakx-backup-do-not-use-c46806bf74c2618daa398cb7c3e4b1c47509a105.tar drakx-backup-do-not-use-c46806bf74c2618daa398cb7c3e4b1c47509a105.tar.gz drakx-backup-do-not-use-c46806bf74c2618daa398cb7c3e4b1c47509a105.tar.bz2 drakx-backup-do-not-use-c46806bf74c2618daa398cb7c3e4b1c47509a105.tar.xz drakx-backup-do-not-use-c46806bf74c2618daa398cb7c3e4b1c47509a105.zip |
even more removals
Diffstat (limited to 'mdk-stage1/dietlibc/libstdio/fgetc.c')
-rw-r--r-- | mdk-stage1/dietlibc/libstdio/fgetc.c | 40 |
1 files changed, 0 insertions, 40 deletions
diff --git a/mdk-stage1/dietlibc/libstdio/fgetc.c b/mdk-stage1/dietlibc/libstdio/fgetc.c deleted file mode 100644 index 90d83961a..000000000 --- a/mdk-stage1/dietlibc/libstdio/fgetc.c +++ /dev/null @@ -1,40 +0,0 @@ -#include "dietstdio.h" -#include <unistd.h> - -extern int feof(FILE *stream); - -int fgetc(FILE *stream) { - unsigned char c; -#ifdef WANT_UNGETC - if (stream->ungotten) { - stream->ungotten=0; - return stream->ungetbuf; - } -#endif - if (feof(stream)) - return EOF; -#ifdef WANT_BUFFERED_STDIO - if (__fflush4(stream,BUFINPUT)) return EOF; - if (stream->bm>=stream->bs) { - int len=read(stream->fd,stream->buf,BUFSIZE); - if (len==0) { - stream->flags|=EOFINDICATOR; - return EOF; - } else if (len<0) { - stream->flags|=ERRORINDICATOR; - return EOF; - } - stream->bm=0; - stream->bs=len; - } - c=stream->buf[stream->bm]; - ++stream->bm; - return c; -#else - if (read(stream->fd,&c,1)!=1) { - stream->flags|=ERRORINDICATOR; - return EOF; - } - return c; -#endif -} |