mirror of
https://sourceware.org/git/glibc.git
synced 2025-07-29 11:41:21 +03:00
[BZ #394]
2005-09-23 Ulrich Drepper <drepper@redhat.com> [BZ #394] * libio/fmemopen.c (fmemopen_write): Return 0 instead of -1 if nothing can be written. * libio/iofopncook.c (_IO_cookie_write): If something went wrong, set error bit.
This commit is contained in:
@ -127,7 +127,7 @@ fmemopen_write (void *cookie, const char *b, size_t s)
|
||||
if ((size_t) (c->pos + addnullc) == c->size)
|
||||
{
|
||||
__set_errno (ENOSPC);
|
||||
return -1;
|
||||
return 0;
|
||||
}
|
||||
s = c->size - c->pos - addnullc;
|
||||
}
|
||||
|
Reference in New Issue
Block a user