Lines Matching refs:cfstr
56 CFStringRef cfstr; in mac_string_convert() local
78 cfstr = CFStringCreateWithBytes(NULL, ptr, len, from, 0); in mac_string_convert()
80 if (cfstr == NULL) in mac_string_convert()
85 while (cfstr == NULL && unconvlenp != NULL && len > 1 && *unconvlenp < 6) in mac_string_convert()
89 cfstr = CFStringCreateWithBytes(NULL, ptr, len, from, 0); in mac_string_convert()
91 if (cfstr == NULL) in mac_string_convert()
101 CFRelease(cfstr); in mac_string_convert()
106 CFRange convertRange = CFRangeMake(0, CFStringGetLength(cfstr)); in mac_string_convert()
108 CFStringGetBytes(cfstr, convertRange, to, NULL, FALSE, NULL, 0, (CFIndex *)&buflen); in mac_string_convert()
111 CFRelease(cfstr); in mac_string_convert()
118 if (!CFStringGetBytes(cfstr, convertRange, to, NULL, FALSE, retval, buflen, NULL)) in mac_string_convert()
120 if (!CFStringGetCString(cfstr, (char *)retval, buflen, to)) in mac_string_convert()
122 CFRelease(cfstr); in mac_string_convert()
138 cfstr = CFStringCreateWithBytes(NULL, ptr + in, l, from, 0); in mac_string_convert()
139 if (cfstr == NULL) in mac_string_convert()
146 if (!CFStringGetCString(cfstr, (char *)d, buflen - out, to)) in mac_string_convert()
157 CFRelease(cfstr); in mac_string_convert()
166 CFRelease(cfstr); in mac_string_convert()
187 CFStringRef cfstr; in macroman2enc() local
193 cfstr = CFStringCreateWithBytes(NULL, ptr, len, in macroman2enc()
199 if (cfstr == NULL) in macroman2enc()
203 r.length = CFStringGetLength(cfstr); in macroman2enc()
204 if (r.length != CFStringGetBytes(cfstr, r, in macroman2enc()
210 CFRelease(cfstr); in macroman2enc()
213 CFRelease(cfstr); in macroman2enc()
237 CFStringRef cfstr; in enc2macroman() local
242 cfstr = CFStringCreateWithBytes(NULL, from, fromlen, in enc2macroman()
245 while (cfstr == NULL && *restlenp < 3 && fromlen > 1) in enc2macroman()
248 cfstr = CFStringCreateWithBytes(NULL, from, fromlen, in enc2macroman()
252 if (cfstr == NULL) in enc2macroman()
256 r.length = CFStringGetLength(cfstr); in enc2macroman()
257 if (r.length != CFStringGetBytes(cfstr, r, in enc2macroman()
264 CFRelease(cfstr); in enc2macroman()
267 CFRelease(cfstr); in enc2macroman()