[Bug 5930] Improper return value of fwrite in bytes,
bugzilla at busybox.net
bugzilla at busybox.net
Thu Feb 14 12:28:21 UTC 2013
https://bugs.busybox.net/show_bug.cgi?id=5930
--- Comment #3 from Bernhard Reutner-Fischer <aldot at uclibc.org> 2013-02-14 12:28:42 UTC ---
(In reply to comment #2)
> (In reply to comment #1)
> > fwrite does return the number of elements written. See libc/stdio/fwrite.c,
> > return __stdio_fwrite()/size.
> >
> > can you please attach your .config (which STDIO_BUFF settings do you use) and
> > it would help if you could also paste an strace -v of your failing test
> > program.
> the same settings work with uClibc09.33. version.
> But in uClibc 09.33.2 if i comment the following part in _WRITE.c
> if (errno != EINTR && errno != EAGAIN) {
> /* do we have other "soft" errors?*/
> break;
> }
> code seems to work fine.
> i have just used a normal fwrite function call with following check
> if(fwrite(buf, sizeof(buf), 1, fp != 1) {
> printf("error %s\n", strerror(errno));
as you can see in the history, Denys did this to drain the buffer.
what errno do you trip there (that was why i was asking for an strace)?
--
Configure bugmail: https://bugs.busybox.net/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are on the CC list for the bug.
More information about the uClibc-cvs
mailing list