as on R5, return an error when *srcLen == 0 and set dstLen to 0
fix bug #120 git-svn-id: file:///srv/svn/repos/haiku/haiku/trunk@16294 a95241bf-73f2-0310-859d-f6bbb57e9c96
This commit is contained in:
@@ -31,7 +31,8 @@ convert_encoding(const char * from, const char * to,
|
|||||||
if (*srcLen == 0) {
|
if (*srcLen == 0) {
|
||||||
// nothing to do!
|
// nothing to do!
|
||||||
DEBPRINT(("nothing to do\n"));
|
DEBPRINT(("nothing to do\n"));
|
||||||
return B_OK;
|
*dstLen = 0;
|
||||||
|
return B_ERROR;
|
||||||
}
|
}
|
||||||
iconv_t conversion = iconv_open(to,from);
|
iconv_t conversion = iconv_open(to,from);
|
||||||
if (conversion == (iconv_t)-1) {
|
if (conversion == (iconv_t)-1) {
|
||||||
|
|||||||
Reference in New Issue
Block a user