From 40fc236df0b0f5d9f61030264e4c82e88719a52e Mon Sep 17 00:00:00 2001 From: Mystery Man Date: Sat, 14 Sep 2002 18:25:46 +0000 Subject: This commit was manufactured by cvs2svn to create tag 'V1_1_9_48mdk'. --- mdk-stage1/dietlibc/libstdio/fread.c | 51 ------------------------------------ 1 file changed, 51 deletions(-) delete mode 100644 mdk-stage1/dietlibc/libstdio/fread.c (limited to 'mdk-stage1/dietlibc/libstdio/fread.c') diff --git a/mdk-stage1/dietlibc/libstdio/fread.c b/mdk-stage1/dietlibc/libstdio/fread.c deleted file mode 100644 index 29afa1489..000000000 --- a/mdk-stage1/dietlibc/libstdio/fread.c +++ /dev/null @@ -1,51 +0,0 @@ -#include -#include "dietstdio.h" -#include - -size_t fread( void *ptr, size_t size, size_t nmemb, FILE *stream) { - int res; -#ifdef WANT_BUFFERED_STDIO - unsigned long i,j; - j=size*nmemb; -#ifdef WANT_UNGETC - if (stream->ungotten) { - *(char*)ptr=stream->ungetbuf; - ptr=((char*)ptr)+1; - --j; - } - if (!j) return 1; -#endif - for (i=0; iungotten) { - *(char*)ptr=stream->ungetbuf; - ptr=((char*)ptr)+1; - --j; - } - if (!j) return 1; - res=read(stream->fd,ptr,j); -#else - res=read(stream->fd,ptr,size*nmemb); -#endif - if (res<0) { - stream->flags|=ERRORINDICATOR; - return 0; - } else if (resflags & UNSEEKABLE) - || ((stream->flags & UNSEEKABLE) && res == 0)) - stream->flags|=EOFINDICATOR; - return res/size; -#endif -} -- cgit v1.2.1