2008-08-27 Corinna Vinschen <corinna@vinschen.de>

* libc/stdlib/wcsrtombs.c (_wcsrtombs_r): Fix condition for
        accepting a converted character and continuing the loop.
This commit is contained in:
Jeff Johnston 2008-08-27 18:31:04 +00:00
parent 7e73b9cfd7
commit 2d8d8175f1
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2008-08-27 Corinna Vinschen <corinna@vinschen.de>
* libc/stdlib/wcsrtombs.c (_wcsrtombs_r): Fix condition for
accepting a converted character and continuing the loop.
2008-07-24 Jeff Johnston <jjohnstn@redhat.com>
* libc/include/ctype.h (_ctype_): Restore for C++ backward

View File

@ -45,7 +45,7 @@ _DEFUN (_wcsrtombs_r, (r, dst, src, len, ps),
ps->__count = 0;
return (size_t)-1;
}
if (n <= len - bytes && bytes < len)
if (n <= len - bytes && bytes <= len)
{
n += bytes;
if (dst)