Lines Matching refs:CH_UCS2
119 if (ch == CH_UCS2) ret = "UCS-2";
215 conv_handles[cur_charset_t][CH_UCS2] = atalk_iconv_open( charset_name(CH_UCS2), name);
216 if (conv_handles[cur_charset_t][CH_UCS2] == (atalk_iconv_t)-1) {
218 name, charset_name(CH_UCS2));
219 conv_handles[cur_charset_t][CH_UCS2] = NULL;
223 conv_handles[CH_UCS2][cur_charset_t] = atalk_iconv_open( name, charset_name(CH_UCS2));
224 if (conv_handles[CH_UCS2][cur_charset_t] == (atalk_iconv_t)-1) {
226 charset_name(CH_UCS2), name);
227 conv_handles[CH_UCS2][cur_charset_t] = NULL;
257 conv_handles[c1][CH_UCS2] = atalk_iconv_open( charset_name(CH_UCS2), name);
258 if (conv_handles[c1][CH_UCS2] == (atalk_iconv_t)-1) {
260 name, charset_name(CH_UCS2));
261 conv_handles[c1][CH_UCS2] = NULL;
264 if (c1 != CH_UCS2) { /* avoid lost memory, make valgrind happy */
265 conv_handles[CH_UCS2][c1] = atalk_iconv_open( name, charset_name(CH_UCS2));
266 if (conv_handles[CH_UCS2][c1] == (atalk_iconv_t)-1) {
268 charset_name(CH_UCS2), name);
269 conv_handles[CH_UCS2][c1] = NULL;
283 if (to == CH_UCS2 && bytesleft >= 2) {
288 else if ( to != CH_UCS2 && bytesleft > 0 )
321 if (from == CH_UCS2) {
372 if ((size_t)-1 == ( o_len = convert_string_internal( from, CH_UCS2, src, srclen,
374 LOG(log_error, logtype_default, "Conversion failed ( %s to CH_UCS2 )", charset_name(from));
394 if ((size_t)(-1) == ( o_len = convert_string_internal( CH_UCS2, to, (char*) u, i_len, dest, destlen)) ) {
395 LOG(log_error, logtype_default, "Conversion failed (CH_UCS2 to %s):%s", charset_name(to), strerror(errno));
476 if (to == CH_UCS2 && o_len >= 2) {
481 else if ( to != CH_UCS2 && o_len > 0 ) {
511 if ((size_t)(-1) == ( o_len = convert_string_internal( from, CH_UCS2, src, srclen,
513 LOG(log_error, logtype_default, "Conversion failed ( %s to CH_UCS2 )", charset_name(from));
534 if ((size_t)-1 == ( o_len = convert_string_allocate_internal( CH_UCS2, to, (char*)u, i_len, dest)) )
535 LOG(log_error, logtype_default, "Conversion failed (CH_UCS2 to %s):%s", charset_name(to), strerror(errno));
546 size = convert_string_allocate_internal(ch, CH_UCS2, src, srclen,
557 size = convert_string_internal(CH_UCS2, ch, buffer, size, dest, destlen);
567 size = convert_string_allocate_internal(ch, CH_UCS2, src, srclen,
578 size = convert_string_internal(CH_UCS2, ch, buffer, size, dest, destlen);
618 return convert_string_allocate(ch, CH_UCS2, src, src_len, (char**) dest);
648 return convert_string(CH_UCS2, ch, src, src_len, dest, destlen);
656 return convert_string_allocate(CH_UCS2, ch, src, src_len, dest);
681 if ((size_t)(-1) == (len = convert_string_allocate_internal(ch, CH_UCS2, src, inlen, &buffer)) )
691 if ((size_t)(-1) == (len = convert_string_internal( CH_UCS2, ch, (char*)u, ilen, dst, outlen)) ) {
707 if ((size_t)(-1) == (len = convert_string_allocate_internal(ch, CH_UCS2, src, inlen, &buffer)) )
717 if ((size_t)(-1) == (len = convert_string_internal( CH_UCS2, ch, (char*)u, ilen, dst, outlen)) ) {
784 descriptor = conv_handles[from_set][CH_UCS2];
785 descriptor_cap = conv_handles[cap_set][CH_UCS2];
894 descriptor = conv_handles[CH_UCS2][to_set];
895 descriptor_cap = conv_handles[CH_UCS2][cap_set];
1044 LOG(log_error, logtype_default, "Conversion failed ( %s to CH_UCS2 )", charset_name(from_set));
1081 "Conversion failed (CH_UCS2 to %s):%s", charset_name(to_set), strerror(errno));