diff options
author | Ulrich Drepper <drepper@redhat.com> | 1999-03-15 20:41:16 +0000 |
---|---|---|
committer | Ulrich Drepper <drepper@redhat.com> | 1999-03-15 20:41:16 +0000 |
commit | b117f744e10e769a5d219cf0b69cc10f81738650 (patch) | |
tree | 35f76b5a32b99735df14db028185e85df3834c33 /wcsmbs/wcsnrtombs.c | |
parent | 1d0b8e4b8f9c636cfaec78be5ebf819d3d8c2284 (diff) | |
download | glibc-b117f744e10e769a5d219cf0b69cc10f81738650.zip glibc-b117f744e10e769a5d219cf0b69cc10f81738650.tar.gz glibc-b117f744e10e769a5d219cf0b69cc10f81738650.tar.bz2 |
Update.
1999-03-15 Ulrich Drepper <drepper@cygnus.com>
* iconv/gconv.h (gconv_fct): Change parameter from `char' to
`unsigned char'.
(gconv_step_data): Likewise.
* iconv/gconv_int.h (__gconv): Likewise.
(__BUILINT_TRANS): Likewise.
* iconv/gconv.c (__gconv): Likewise.
* iconv/iconv.c (iconv): Add casts for call of __gconv.
* iconv/skeleton.c: Change local parameters and variable from `char' to
`unsigned char'. Remove casts from calls into modules.
* iconvdata/iso-2022-jp.c (gconv): Change local variable outbuf from
`char' to `unsigned char'.
* wcsmbs/btowc.c: Change pointers from `char *' to `unsigned char *'.
* wcsmbs/mbrtowc.c: Likewise.
* wcsmbs/mbsnrtowcs.c: Likewise.
* wcsmbs/mbsrtowcs.c: Likewise.
* wcsmbs/wcrtomb.c: Likewise.
* wcsmbs/wcsnrtombs.c: Likewise.
* wcsmbs/wcsrtombs.c: Likewise.
* wcsmbs/wctob.c: Likewise.
Diffstat (limited to 'wcsmbs/wcsnrtombs.c')
-rw-r--r-- | wcsmbs/wcsnrtombs.c | 15 |
1 files changed, 8 insertions, 7 deletions
diff --git a/wcsmbs/wcsnrtombs.c b/wcsmbs/wcsnrtombs.c index 18537c2..f93d404 100644 --- a/wcsmbs/wcsnrtombs.c +++ b/wcsmbs/wcsnrtombs.c @@ -64,7 +64,7 @@ __wcsnrtombs (dst, src, nwc, len, ps) /* We have to handle DST == NULL special. */ if (dst == NULL) { - char buf[256]; /* Just an arbitrary value. */ + unsigned char buf[256]; /* Just an arbitrary value. */ const wchar_t *inbuf = *src; size_t dummy; @@ -77,8 +77,8 @@ __wcsnrtombs (dst, src, nwc, len, ps) status = (*__wcsmbs_gconv_fcts.tomb->fct) (__wcsmbs_gconv_fcts.tomb, &data, - (const char **) &inbuf, - (const char *) srcend, + (const unsigned char **) &inbuf, + (const unsigned char *) srcend, &dummy, 0); /* Count the number of bytes. */ @@ -102,19 +102,20 @@ __wcsnrtombs (dst, src, nwc, len, ps) data.outbufend = dst + len; status = (*__wcsmbs_gconv_fcts.tomb->fct) (__wcsmbs_gconv_fcts.tomb, - &data, (const char **) src, - (const char *) srcend, + &data, + (const unsigned char **) src, + (const unsigned char *) srcend, &dummy, 0); /* Count the number of bytes. */ - result = data.outbuf - dst; + result = data.outbuf - (unsigned char *) dst; /* We have to determine whether the last character converted is the NUL character. */ if ((status == GCONV_OK || status == GCONV_EMPTY_INPUT) && data.outbuf[-1] == '\0') { - assert (data.outbuf != dst); + assert (data.outbuf != (unsigned char *) dst); assert (__mbsinit (data.statep)); *src = NULL; --result; |