Lines Matching refs:err

201 static void _php_iconv_show_error(php_iconv_err_t err, const char *out_charset, const char *in_char…
731 php_iconv_err_t err = PHP_ICONV_ERR_SUCCESS; in _php_iconv_strlen() local
782 err = PHP_ICONV_ERR_ILLEGAL_CHAR; in _php_iconv_strlen()
786 err = PHP_ICONV_ERR_ILLEGAL_SEQ; in _php_iconv_strlen()
795 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_strlen()
804 return err; in _php_iconv_strlen()
815 php_iconv_err_t err = PHP_ICONV_ERR_SUCCESS; in _php_iconv_substr() local
829 err = _php_iconv_strlen(&total_len, str, nbytes, enc); in _php_iconv_substr()
830 if (err != PHP_ICONV_ERR_SUCCESS) { in _php_iconv_substr()
831 return err; in _php_iconv_substr()
903 err = PHP_ICONV_ERR_WRONG_CHARSET; in _php_iconv_substr()
905 err = PHP_ICONV_ERR_CONVERTER; in _php_iconv_substr()
908 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_substr()
925 err = PHP_ICONV_ERR_ILLEGAL_CHAR; in _php_iconv_substr()
929 err = PHP_ICONV_ERR_ILLEGAL_SEQ; in _php_iconv_substr()
936 if (err == PHP_ICONV_ERR_SUCCESS) { in _php_iconv_substr()
950 return err; in _php_iconv_substr()
963 php_iconv_err_t err = PHP_ICONV_ERR_SUCCESS; in _php_iconv_strpos() local
985 err = php_iconv_string(ndl, ndl_nbytes, &ndl_buf, GENERIC_SUPERSET_NAME, enc); in _php_iconv_strpos()
987 if (err != PHP_ICONV_ERR_SUCCESS) { in _php_iconv_strpos()
991 return err; in _php_iconv_strpos()
1030 err = PHP_ICONV_ERR_ILLEGAL_CHAR; in _php_iconv_strpos()
1034 err = PHP_ICONV_ERR_ILLEGAL_SEQ; in _php_iconv_strpos()
1041 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_strpos()
1139 return err; in _php_iconv_strpos()
1146 php_iconv_err_t err = PHP_ICONV_ERR_SUCCESS; in _php_iconv_mime_encode() local
1182 err = PHP_ICONV_ERR_TOO_BIG; in _php_iconv_mime_encode()
1190 err = PHP_ICONV_ERR_WRONG_CHARSET; in _php_iconv_mime_encode()
1192 err = PHP_ICONV_ERR_CONVERTER; in _php_iconv_mime_encode()
1195 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_encode()
1204 err = PHP_ICONV_ERR_WRONG_CHARSET; in _php_iconv_mime_encode()
1206 err = PHP_ICONV_ERR_CONVERTER; in _php_iconv_mime_encode()
1209 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_encode()
1265 err = PHP_ICONV_ERR_TOO_BIG; in _php_iconv_mime_encode()
1275 err = PHP_ICONV_ERR_ILLEGAL_CHAR; in _php_iconv_mime_encode()
1279 err = PHP_ICONV_ERR_ILLEGAL_SEQ; in _php_iconv_mime_encode()
1284 err = PHP_ICONV_ERR_TOO_BIG; in _php_iconv_mime_encode()
1290 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_encode()
1295 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_encode()
1306 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_encode()
1311 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_encode()
1320 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_encode()
1335 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_encode()
1376 err = PHP_ICONV_ERR_ILLEGAL_CHAR; in _php_iconv_mime_encode()
1380 err = PHP_ICONV_ERR_ILLEGAL_SEQ; in _php_iconv_mime_encode()
1385 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_encode()
1391 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_encode()
1396 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_encode()
1407 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_encode()
1412 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_encode()
1448 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_encode()
1471 return err; in _php_iconv_mime_encode()
1478 php_iconv_err_t err = PHP_ICONV_ERR_SUCCESS; in _php_iconv_mime_decode() local
1503 err = PHP_ICONV_ERR_WRONG_CHARSET; in _php_iconv_mime_decode()
1505 err = PHP_ICONV_ERR_CONVERTER; in _php_iconv_mime_decode()
1508 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_decode()
1539 err = _php_iconv_appendc(pretval, *p1, cd_pl); in _php_iconv_mime_decode()
1540 if (err != PHP_ICONV_ERR_SUCCESS) { in _php_iconv_mime_decode()
1542 err = PHP_ICONV_ERR_SUCCESS; in _php_iconv_mime_decode()
1560 err = _php_iconv_appendl(pretval, encoded_word, (size_t)((p1 + 1) - encoded_word), cd_pl); in _php_iconv_mime_decode()
1561 if (err != PHP_ICONV_ERR_SUCCESS) { in _php_iconv_mime_decode()
1590 err = _php_iconv_appendl(pretval, csname, (size_t)((p1 + 1) - csname), cd_pl); in _php_iconv_mime_decode()
1591 if (err != PHP_ICONV_ERR_SUCCESS) { in _php_iconv_mime_decode()
1607 err = PHP_ICONV_ERR_MALFORMED; in _php_iconv_mime_decode()
1615 err = _php_iconv_appendl(pretval, encoded_word, (size_t)((p1 + 1) - encoded_word), cd_pl); in _php_iconv_mime_decode()
1616 if (err != PHP_ICONV_ERR_SUCCESS) { in _php_iconv_mime_decode()
1627 err = PHP_ICONV_ERR_MALFORMED; in _php_iconv_mime_decode()
1673 err = _php_iconv_appendl(pretval, encoded_word, (size_t)((p1 + 1) - encoded_word), cd_pl); in _php_iconv_mime_decode()
1674 if (err != PHP_ICONV_ERR_SUCCESS) { in _php_iconv_mime_decode()
1686 err = PHP_ICONV_ERR_WRONG_CHARSET; in _php_iconv_mime_decode()
1688 err = PHP_ICONV_ERR_CONVERTER; in _php_iconv_mime_decode()
1691 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_decode()
1715 err = _php_iconv_appendl(pretval, encoded_word, (size_t)((p1 + 1) - encoded_word), cd_pl); in _php_iconv_mime_decode()
1716 if (err != PHP_ICONV_ERR_SUCCESS) { in _php_iconv_mime_decode()
1727 err = PHP_ICONV_ERR_MALFORMED; in _php_iconv_mime_decode()
1737 err = _php_iconv_appendl(pretval, encoded_word, (size_t)((p1 + 1) - encoded_word), cd_pl); in _php_iconv_mime_decode()
1738 if (err != PHP_ICONV_ERR_SUCCESS) { in _php_iconv_mime_decode()
1749 err = PHP_ICONV_ERR_MALFORMED; in _php_iconv_mime_decode()
1793 err = _php_iconv_appendl(pretval, encoded_word, (size_t)((p1 + 1) - encoded_word), cd_pl); in _php_iconv_mime_decode()
1794 if (err != PHP_ICONV_ERR_SUCCESS) { in _php_iconv_mime_decode()
1805 err = PHP_ICONV_ERR_MALFORMED; in _php_iconv_mime_decode()
1830 err = _php_iconv_appendl(pretval, encoded_word, (size_t)((p1 + 1) - encoded_word), cd_pl); in _php_iconv_mime_decode()
1831 if (err != PHP_ICONV_ERR_SUCCESS) { in _php_iconv_mime_decode()
1859 err = _php_iconv_appendl(pretval, encoded_word, (size_t)((p1 + 1) - encoded_word), cd_pl); in _php_iconv_mime_decode()
1860 if (err != PHP_ICONV_ERR_SUCCESS) { in _php_iconv_mime_decode()
1871 err = PHP_ICONV_ERR_UNKNOWN; in _php_iconv_mime_decode()
1876 err = _php_iconv_appendl(pretval, ZSTR_VAL(decoded_text), ZSTR_LEN(decoded_text), cd); in _php_iconv_mime_decode()
1879 if (err != PHP_ICONV_ERR_SUCCESS) { in _php_iconv_mime_decode()
1882 err = _php_iconv_appendl(pretval, encoded_word, (size_t)(p1 - encoded_word), cd_pl); in _php_iconv_mime_decode()
1884 if (err != PHP_ICONV_ERR_SUCCESS) { in _php_iconv_mime_decode()
2006 err = PHP_ICONV_ERR_SUCCESS; in _php_iconv_mime_decode()
2008 err = PHP_ICONV_ERR_MALFORMED; in _php_iconv_mime_decode()
2032 return err; in _php_iconv_mime_decode()
2037 static void _php_iconv_show_error(php_iconv_err_t err, const char *out_charset, const char *in_char… in _php_iconv_show_error() argument
2039 switch (err) { in _php_iconv_show_error()
2085 php_iconv_err_t err; in PHP_FUNCTION() local
2099 err = _php_iconv_strlen(&retval, ZSTR_VAL(str), ZSTR_LEN(str), charset); in PHP_FUNCTION()
2100 _php_iconv_show_error(err, GENERIC_SUPERSET_NAME, charset); in PHP_FUNCTION()
2101 if (err == PHP_ICONV_ERR_SUCCESS) { in PHP_FUNCTION()
2118 php_iconv_err_t err; in PHP_FUNCTION() local
2137 err = _php_iconv_substr(&retval, ZSTR_VAL(str), ZSTR_LEN(str), offset, length, charset); in PHP_FUNCTION()
2138 _php_iconv_show_error(err, GENERIC_SUPERSET_NAME, charset); in PHP_FUNCTION()
2140 if (err == PHP_ICONV_ERR_SUCCESS && ZSTR_LEN(str) >= 0 && retval.s != NULL) { in PHP_FUNCTION()
2158 php_iconv_err_t err; in PHP_FUNCTION() local
2175 err = _php_iconv_strlen(&haystk_len, ZSTR_VAL(haystk), ZSTR_LEN(haystk), charset); in PHP_FUNCTION()
2176 if (err != PHP_ICONV_ERR_SUCCESS) { in PHP_FUNCTION()
2177 _php_iconv_show_error(err, GENERIC_SUPERSET_NAME, charset); in PHP_FUNCTION()
2191 err = _php_iconv_strpos(&retval, ZSTR_VAL(haystk), ZSTR_LEN(haystk), ZSTR_VAL(ndl), ZSTR_LEN(ndl), in PHP_FUNCTION()
2193 _php_iconv_show_error(err, GENERIC_SUPERSET_NAME, charset); in PHP_FUNCTION()
2195 if (err == PHP_ICONV_ERR_SUCCESS && retval != (size_t)-1) { in PHP_FUNCTION()
2212 php_iconv_err_t err; in PHP_FUNCTION() local
2231 err = _php_iconv_strpos(&retval, ZSTR_VAL(haystk), ZSTR_LEN(haystk), ZSTR_VAL(ndl), ZSTR_LEN(ndl), in PHP_FUNCTION()
2233 _php_iconv_show_error(err, GENERIC_SUPERSET_NAME, charset); in PHP_FUNCTION()
2235 if (err == PHP_ICONV_ERR_SUCCESS && retval != (size_t)-1) { in PHP_FUNCTION()
2252 php_iconv_err_t err; in PHP_FUNCTION() local
2321 err = _php_iconv_mime_encode(&retval, ZSTR_VAL(field_name), ZSTR_LEN(field_name), in PHP_FUNCTION()
2324 _php_iconv_show_error(err, out_charset, in_charset); in PHP_FUNCTION()
2326 if (err == PHP_ICONV_ERR_SUCCESS) { in PHP_FUNCTION()
2354 php_iconv_err_t err; in PHP_FUNCTION() local
2367err = _php_iconv_mime_decode(&retval, ZSTR_VAL(encoded_str), ZSTR_LEN(encoded_str), charset, NULL,… in PHP_FUNCTION()
2368 _php_iconv_show_error(err, charset, "???"); in PHP_FUNCTION()
2370 if (err == PHP_ICONV_ERR_SUCCESS) { in PHP_FUNCTION()
2394 php_iconv_err_t err = PHP_ICONV_ERR_SUCCESS; in PHP_FUNCTION() local
2420 …if (PHP_ICONV_ERR_SUCCESS != (err = _php_iconv_mime_decode(&decoded_header, enc_str_tmp, enc_str_l… in PHP_FUNCTION()
2473 if (err != PHP_ICONV_ERR_SUCCESS) { in PHP_FUNCTION()
2474 _php_iconv_show_error(err, charset, "???"); in PHP_FUNCTION()
2488 php_iconv_err_t err; in PHP_NAMED_FUNCTION() local
2500err = php_iconv_string(ZSTR_VAL(in_buffer), (size_t)ZSTR_LEN(in_buffer), &out_buffer, out_charset,… in PHP_NAMED_FUNCTION()
2501 _php_iconv_show_error(err, out_charset, in_charset); in PHP_NAMED_FUNCTION()
2502 if (err == PHP_ICONV_ERR_SUCCESS && out_buffer != NULL) { in PHP_NAMED_FUNCTION()