Mercurial > hg > octave-lojdl > gnulib-hg
changeset 9925:e5667160faa8
Fix bug in error handling code.
author | Bruno Haible <bruno@clisp.org> |
---|---|
date | Wed, 16 Apr 2008 03:35:29 +0200 |
parents | 01ca1a0b2ebe |
children | 1882f5a7e6c5 |
files | ChangeLog lib/uniconv/u-conv-to-enc.h |
diffstat | 2 files changed, 7 insertions(+), 2 deletions(-) [+] |
line wrap: on
line diff
--- a/ChangeLog +++ b/ChangeLog @@ -1,3 +1,8 @@ +2008-04-15 Bruno Haible <bruno@clisp.org> + + * lib/uniconv/u-conv-to-enc.h (FUNC): Fix return value when U_TO_U8 + fails. + 2008-04-15 Bruno Haible <bruno@clisp.org> * lib/trim.c (trim2): Fix argument of isspace() macro.
--- a/lib/uniconv/u-conv-to-enc.h +++ b/lib/uniconv/u-conv-to-enc.h @@ -1,5 +1,5 @@ /* Conversion from UTF-16/UTF-32 to legacy encodings. - Copyright (C) 2002, 2006-2007 Free Software Foundation, Inc. + Copyright (C) 2002, 2006-2008 Free Software Foundation, Inc. This program is free software: you can redistribute it and/or modify it under the terms of the GNU Lesser General Public License as published @@ -67,7 +67,7 @@ utf8_src = U_TO_U8 (src, srclen, tmpbuf, &tmpbufsize); if (utf8_src == NULL) - return NULL; + return -1; utf8_srclen = tmpbufsize; if (offsets != NULL)