Lines Matching refs:maxoutput
440 uint8_t *utf8, unsigned int maxoutput) in UTF16ToUTF8() argument
447 if (!utf16 || !maxinput || !utf8 || !maxoutput) in UTF16ToUTF8()
450 maxoutput--; /* plan for termination now */ in UTF16ToUTF8()
453 s16idx < maxinput && utf16[s16idx] && maxoutput; in UTF16ToUTF8()
482 if (code_point <= 0x7F && maxoutput >= 1) { in UTF16ToUTF8()
483 maxoutput -= 1; in UTF16ToUTF8()
485 } else if (code_point <= 0x7FF && maxoutput >= 2) { in UTF16ToUTF8()
486 maxoutput -= 2; in UTF16ToUTF8()
489 } else if (code_point <= 0xFFFF && maxoutput >= 3) { in UTF16ToUTF8()
490 maxoutput -= 3; in UTF16ToUTF8()
494 } else if (code_point <= 0x10FFFF && maxoutput >= 4) { in UTF16ToUTF8()
495 maxoutput -= 4; in UTF16ToUTF8()
528 int UTF8ToUTF16(const uint8_t *utf8, uint16_t *utf16, unsigned int maxoutput) in UTF8ToUTF16() argument
536 if (!utf8 || !utf16 || !maxoutput) in UTF8ToUTF16()
539 maxoutput--; /* plan for termination */ in UTF8ToUTF16()
542 utf8[s8idx] && maxoutput; in UTF8ToUTF16()
603 maxoutput -= 1; in UTF8ToUTF16()
605 maxoutput >= 2) { in UTF8ToUTF16()
608 maxoutput -= 2; in UTF8ToUTF16()