From: Ulrich Drepper Date: Tue, 21 Dec 1999 07:23:26 +0000 (+0000) Subject: (__gconv): Deal with outbuf being NULL. X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=49b1daec73a8f16cb752ec00d56c8c5698c4e123;p=thirdparty%2Fglibc.git (__gconv): Deal with outbuf being NULL. --- diff --git a/iconv/gconv.c b/iconv/gconv.c index 16a6b8fb94e..0bef7929806 100644 --- a/iconv/gconv.c +++ b/iconv/gconv.c @@ -40,7 +40,7 @@ __gconv (gconv_t cd, const unsigned char **inbuf, assert (converted != NULL); *converted = 0; - cd->data[last_step].outbuf = *outbuf; + cd->data[last_step].outbuf = outbuf != NULL ? *outbuf : NULL; cd->data[last_step].outbufend = outbufend; if (inbuf == NULL || *inbuf == NULL)