Lines Matching refs:ulen

76     file_unichar_t **ubuf, size_t *ulen, const char **code,  in file_encoding()  argument
89 if (ulen == NULL) in file_encoding()
90 ulen = &udeflen; in file_encoding()
93 *ulen = 0; in file_encoding()
113 if (looks_ascii(buf, nbytes, *ubuf, ulen)) { in file_encoding()
114 if (looks_utf7(buf, nbytes, *ubuf, ulen) > 0) { in file_encoding()
115 DPRINTF(("utf-7 %" SIZE_T_FORMAT "u\n", *ulen)); in file_encoding()
119 DPRINTF(("ascii %" SIZE_T_FORMAT "u\n", *ulen)); in file_encoding()
123 } else if (looks_utf8_with_BOM(buf, nbytes, *ubuf, ulen) > 0) { in file_encoding()
124 DPRINTF(("utf8/bom %" SIZE_T_FORMAT "u\n", *ulen)); in file_encoding()
127 } else if (file_looks_utf8(buf, nbytes, *ubuf, ulen) > 1) { in file_encoding()
128 DPRINTF(("utf8 %" SIZE_T_FORMAT "u\n", *ulen)); in file_encoding()
131 } else if ((ucs_type = looks_ucs32(buf, nbytes, *ubuf, ulen)) != 0) { in file_encoding()
139 DPRINTF(("ucs32 %" SIZE_T_FORMAT "u\n", *ulen)); in file_encoding()
140 } else if ((ucs_type = looks_ucs16(buf, nbytes, *ubuf, ulen)) != 0) { in file_encoding()
148 DPRINTF(("ucs16 %" SIZE_T_FORMAT "u\n", *ulen)); in file_encoding()
149 } else if (looks_latin1(buf, nbytes, *ubuf, ulen)) { in file_encoding()
150 DPRINTF(("latin1 %" SIZE_T_FORMAT "u\n", *ulen)); in file_encoding()
153 } else if (looks_extended(buf, nbytes, *ubuf, ulen)) { in file_encoding()
154 DPRINTF(("extended %" SIZE_T_FORMAT "u\n", *ulen)); in file_encoding()
160 if (looks_ascii(nbuf, nbytes, *ubuf, ulen)) { in file_encoding()
161 DPRINTF(("ebcdic %" SIZE_T_FORMAT "u\n", *ulen)); in file_encoding()
164 } else if (looks_latin1(nbuf, nbytes, *ubuf, ulen)) { in file_encoding()
166 *ulen)); in file_encoding()
266 size_t *ulen) \
272 *ulen = 0; \
280 ubuf[(*ulen)++] = buf[i]; \
363 size_t *ulen) in file_looks_utf8() argument
371 *ulen = 0; in file_looks_utf8()
384 ubuf[(*ulen)++] = buf[i]; in file_looks_utf8()
428 ubuf[(*ulen)++] = c; in file_looks_utf8()
443 file_unichar_t *ubuf, size_t *ulen) in looks_utf8_with_BOM() argument
446 return file_looks_utf8(buf + 3, nbytes - 3, ubuf, ulen); in looks_utf8_with_BOM()
453 size_t *ulen) in looks_utf7() argument
462 *ulen = 0; in looks_utf7()
473 size_t *ulen) in looks_ucs16() argument
488 *ulen = 0; in looks_ucs16()
494 ubf[(*ulen)++] = bf[i + 1] in looks_ucs16()
497 ubf[(*ulen)++] = bf[i] in looks_ucs16()
500 if (ubf[*ulen - 1] == 0xfffe) in looks_ucs16()
502 if (ubf[*ulen - 1] < 128 && in looks_ucs16()
503 text_chars[CAST(size_t, ubf[*ulen - 1])] != T) in looks_ucs16()
512 size_t *ulen) in looks_ucs32() argument
527 *ulen = 0; in looks_ucs32()
533 ubf[(*ulen)++] = CAST(file_unichar_t, bf[i + 3]) in looks_ucs32()
538 ubf[(*ulen)++] = CAST(file_unichar_t, bf[i + 0]) in looks_ucs32()
543 if (ubf[*ulen - 1] == 0xfffe) in looks_ucs32()
545 if (ubf[*ulen - 1] < 128 && in looks_ucs32()
546 text_chars[CAST(size_t, ubf[*ulen - 1])] != T) in looks_ucs32()