diff options
author | Ulrich Drepper <drepper@redhat.com> | 2005-09-23 16:36:09 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 2005-09-23 16:36:09 +0000 |
commit | 32053042d4785ffeae3a032808480c8dc2f98607 (patch) | |
tree | bfa6fb199b0f47051f624eb2d93778e54fcd2989 /libio/fmemopen.c | |
parent | 997470b3e151845b067b0a7c865f9ab7177d14c1 (diff) | |
download | glibc-32053042d4785ffeae3a032808480c8dc2f98607.zip glibc-32053042d4785ffeae3a032808480c8dc2f98607.tar.gz glibc-32053042d4785ffeae3a032808480c8dc2f98607.tar.bz2 |
[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.
Diffstat (limited to 'libio/fmemopen.c')
-rw-r--r-- | libio/fmemopen.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/libio/fmemopen.c b/libio/fmemopen.c index 7c8769a..b847f62 100644 --- a/libio/fmemopen.c +++ b/libio/fmemopen.c @@ -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; } |