diff options
author | trawick <trawick@13f79535-47bb-0310-9956-ffa450edef68> | 2000-08-20 04:14:49 +0000 |
---|---|---|
committer | trawick <trawick@13f79535-47bb-0310-9956-ffa450edef68> | 2000-08-20 04:14:49 +0000 |
commit | 0f7c27bf94125eddd71a7afde4d897d01a9d2308 (patch) | |
tree | 947b0ef1dd88764ae163c1fef9b51bea388c7d30 /i18n | |
parent | 1210438dc8c1fe55ae28610b039572b1bdd2319a (diff) | |
download | libapr-0f7c27bf94125eddd71a7afde4d897d01a9d2308.tar.gz |
Remove some casts in calls to iconv().
git-svn-id: http://svn.apache.org/repos/asf/apr/apr/trunk@60507 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'i18n')
-rw-r--r-- | i18n/unix/xlate.c | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/i18n/unix/xlate.c b/i18n/unix/xlate.c index acd2e58c1..6ff40c679 100644 --- a/i18n/unix/xlate.c +++ b/i18n/unix/xlate.c @@ -174,7 +174,8 @@ static apr_status_t apr_xlate_cleanup(void *convset) static void check_sbcs(apr_xlate_t *convset) { char inbuf[256], outbuf[256]; - char *inbufptr = inbuf, *outbufptr = outbuf; + const char *inbufptr = inbuf; + char *outbufptr = outbuf; size_t inbytes_left, outbytes_left; int i; size_t translated; @@ -184,7 +185,7 @@ static void check_sbcs(apr_xlate_t *convset) } inbytes_left = outbytes_left = sizeof(inbuf); - translated = iconv(convset->ich, (const char **)&inbufptr, + translated = iconv(convset->ich, &inbufptr, &inbytes_left, &outbufptr, &outbytes_left); if (translated != (size_t) -1 && inbytes_left == 0 && @@ -275,10 +276,10 @@ apr_status_t apr_xlate_conv_buffer(apr_xlate_t *convset, const char *inbuf, size_t translated; if (convset->ich != (iconv_t)-1) { - char *inbufptr = (char *)inbuf; + const char *inbufptr = inbuf; char *outbufptr = outbuf; - translated = iconv(convset->ich, (const char **)&inbufptr, + translated = iconv(convset->ich, &inbufptr, inbytes_left, &outbufptr, outbytes_left); /* If everything went fine but we ran out of buffer, don't * report it as an error. Caller needs to look at the two |