summaryrefslogtreecommitdiff
path: root/lib/util/charset/charcnv.c
diff options
context:
space:
mode:
authorJeremy Allison <jra@samba.org>2011-03-30 13:08:31 -0700
committerJeremy Allison <jra@samba.org>2011-03-30 23:59:37 +0200
commitc109a70531de72eef30a695248b91704bd0c7c24 (patch)
tree29182afa1ae334e8aee0e71e59aa1a0e5de65f6a /lib/util/charset/charcnv.c
parent9ede19fdccaf09303012208129a093197403ef2c (diff)
downloadsamba-c109a70531de72eef30a695248b91704bd0c7c24.tar.gz
samba-c109a70531de72eef30a695248b91704bd0c7c24.tar.bz2
samba-c109a70531de72eef30a695248b91704bd0c7c24.zip
Fix convert_string() to take a *converted_size arg. and return a bool.
Makes these interfaces much harder to misuse and easier to ensure error checking. Autobuild-User: Jeremy Allison <jra@samba.org> Autobuild-Date: Wed Mar 30 23:59:37 CEST 2011 on sn-devel-104
Diffstat (limited to 'lib/util/charset/charcnv.c')
-rw-r--r--lib/util/charset/charcnv.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/lib/util/charset/charcnv.c b/lib/util/charset/charcnv.c
index 3b7dbb3074..cefc788f79 100644
--- a/lib/util/charset/charcnv.c
+++ b/lib/util/charset/charcnv.c
@@ -184,12 +184,12 @@ _PUBLIC_ bool convert_string_handle(struct smb_iconv_handle *ic,
case E2BIG:
reason="No more room";
if (from == CH_UNIX) {
- DEBUG(0,("E2BIG: convert_string(%s,%s): srclen=%d destlen=%d - '%s'\n",
+ DEBUG(0,("E2BIG: convert_string_handle(%s,%s): srclen=%d destlen=%d - '%s'\n",
charset_name(ic, from), charset_name(ic, to),
(int)srclen, (int)destlen,
(const char *)src));
} else {
- DEBUG(0,("E2BIG: convert_string(%s,%s): srclen=%d destlen=%d\n",
+ DEBUG(0,("E2BIG: convert_string_handle(%s,%s): srclen=%d destlen=%d\n",
charset_name(ic, from), charset_name(ic, to),
(int)srclen, (int)destlen));
}
@@ -233,7 +233,7 @@ _PUBLIC_ bool convert_string_talloc_handle(TALLOC_CTX *ctx,
if (descriptor == (smb_iconv_t)-1 || descriptor == (smb_iconv_t)0) {
/* conversion not supported, return -1*/
- DEBUG(3, ("convert_string_talloc: conversion from %s to %s not supported!\n",
+ DEBUG(3, ("convert_string_talloc_handle: conversion from %s to %s not supported!\n",
charset_name(ic, from),
charset_name(ic, to)));
return false;