Lines Matching refs:size_t

118 int php_tag_find(char *tag, size_t len, const char *set);
138 static zend_string *php_bin2hex(const unsigned char *old, const size_t oldlen) in php_bin2hex()
141 size_t i, j; in php_bin2hex()
157 static zend_string *php_hex2bin(const unsigned char *old, const size_t oldlen) in php_hex2bin()
159 size_t target_length = oldlen >> 1; in php_hex2bin()
162 size_t i, j; in php_hex2bin()
321 } else if ((size_t)start > ZSTR_LEN(s11)) { in php_spn_common_handler()
751 static inline int php_charmask(unsigned char *input, size_t len, char *mask) in php_charmask()
800 static zend_always_inline zend_string *php_trim_int(zend_string *str, char *what, size_t what_len, … in php_trim_int()
892 PHPAPI zend_string *php_trim(zend_string *str, char *what, size_t what_len, int mode) in php_trim()
946 size_t newtextlen, chk, breakchar_len = 1; in PHP_FUNCTION()
947 size_t alloced; in PHP_FUNCTION()
1000 chk = (size_t)(ZSTR_LEN(text)/linelength + 1); in PHP_FUNCTION()
1015 alloced += (size_t) (((ZSTR_LEN(text) - current + 1)/linelength + 1) * breakchar_len) + 1; in PHP_FUNCTION()
1017 chk = (size_t) ((ZSTR_LEN(text) - current)/linelength) + 1; in PHP_FUNCTION()
1098 size_t l = p2 - p1; in php_explode()
1136 size_t allocated = EXPLODE_ALLOC_STEP, found = 0; in php_explode_negative_limit()
1215 size_t len = 0; in php_implode()
1337 size_t skipped = 0; in PHP_FUNCTION()
1407 PHPAPI char *php_strtoupper(char *s, size_t len) in php_strtoupper()
1470 PHPAPI char *php_strtolower(char *s, size_t len) in php_strtolower()
1533 PHPAPI zend_string *php_basename(const char *s, size_t len, char *suffix, size_t sufflen)
1536 size_t inc_len, cnt;
1599 if (suffix != NULL && sufflen < (size_t)(cend - comp) &&
1616 size_t string_len, suffix_len = 0;
1630 PHPAPI size_t php_dirname(char *path, size_t len)
1641 size_t str_len;
1685 size_t path_len;
1766 PHPAPI char *php_stristr(char *s, char *t, size_t s_len, size_t t_len)
1776 PHPAPI size_t php_strspn(char *s1, char *s2, char *s1_end, char *s2_end)
1794 PHPAPI size_t php_strcspn(char *s1, char *s2, char *s1_end, char *s2_end)
1847 size_t found_offset;
1966 if (offset < 0 || (size_t)offset > ZSTR_LEN(haystack)) {
2022 if (offset < 0 || (size_t)offset > ZSTR_LEN(haystack)) {
2074 size_t needle_len;
2103 if ((size_t)offset > ZSTR_LEN(haystack)) {
2107 p = ZSTR_VAL(haystack) + (size_t)offset;
2110 if (offset < -INT_MAX || (size_t)(-offset) > ZSTR_LEN(haystack)) {
2115 if ((size_t)-offset < needle_len) {
2171 if ((size_t)offset > ZSTR_LEN(haystack)) {
2176 p = ZSTR_VAL(haystack) + (size_t)offset;
2180 if (offset < -INT_MAX || (size_t)(-offset) > ZSTR_LEN(haystack)) {
2185 e = ZSTR_VAL(haystack) + ZSTR_LEN(haystack) + (size_t)offset;
2202 if ((size_t)offset > ZSTR_LEN(haystack)) {
2211 if (offset < -INT_MAX || (size_t)(-offset) > ZSTR_LEN(haystack)) {
2218 if ((size_t)-offset < ZSTR_LEN(needle)) {
2276 static zend_string *php_chunk_split(char *src, size_t srclen, char *end, size_t endlen, size_t chun…
2279 size_t chunks; /* complete chunks! */
2280 size_t restlen;
2281 size_t out_len;
2330 size_t endlen = 2;
2346 if ((size_t)chunklen > ZSTR_LEN(str)) {
2359 result = php_chunk_split(ZSTR_VAL(str), ZSTR_LEN(str), end, endlen, (size_t)chunklen);
2385 if ((l < 0 && (size_t)(-l) > ZSTR_LEN(str))) {
2396 } else if (f < 0 && (size_t)-f > ZSTR_LEN(str)) {
2428 if ((size_t)l > ZSTR_LEN(str) - (size_t)f) {
2518 } else if ((size_t)f > Z_STRLEN_P(str)) {
2531 if ((size_t)l > Z_STRLEN_P(str) || (l < 0 && (size_t)(-l) > Z_STRLEN_P(str))) {
2575 size_t result_len;
2760 size_t str_len;
2855 size_t delims_len = 6;
2884 PHPAPI char *php_strtr(char *str, size_t len, char *str_from, char *str_to, size_t trlen)
2886 size_t i;
2905 xlat[(size_t)(unsigned char) str_from[i]] = str_to[i];
2909 str[i] = xlat[(size_t)(unsigned char) str[i]];
2919 static zend_string *php_strtr_ex(zend_string *str, char *str_from, char *str_to, size_t trlen)
2922 size_t i;
2947 xlat[(size_t)(unsigned char) str_from[i]] = str_to[i];
2951 if (ZSTR_VAL(str)[i] != xlat[(size_t)(unsigned char) ZSTR_VAL(str)[i]]) {
2954 ZSTR_VAL(new_str)[i] = xlat[(size_t)(unsigned char) ZSTR_VAL(str)[i]];
2960 ZSTR_VAL(new_str)[i] = xlat[(size_t)(unsigned char) ZSTR_VAL(str)[i]];
2977 size_t slen = ZSTR_LEN(input);
2980 size_t len, pos, old_pos;
2982 size_t minlen = 128*1024;
2983 size_t maxlen = 0;
3112 static zend_string* php_char_to_str_ex(zend_string *str, char from, char *to, size_t to_len, int ca…
3115 size_t char_count = 0;
3184 char *needle, size_t needle_len, char *str, size_t str_len, zend_long *replace_count)
3207 size_t count = 0;
3265 zend_string *needle, char *str, size_t str_len, zend_long *replace_count)
3291 size_t count = 0;
3358 …zend_string *php_str_to_str(char *haystack, size_t length, char *needle, size_t needle_len, char *…
3377 size_t count = 0;
3435 size_t to_len = 0;
3535 …id php_similar_str(const char *txt1, size_t len1, const char *txt2, size_t len2, size_t *pos1, siz…
3540 size_t l;
3558 static size_t php_similar_char(const char *txt1, size_t len1, const char *txt2, size_t len2)
3560 size_t sum;
3561 size_t pos1 = 0, pos2 = 0, max;
3586 size_t sim;
3623 size_t l;
3748 size_t nlen = ZSTR_LEN(str), i;
3808 PHPAPI zend_string *php_addcslashes(zend_string *str, int should_free, char *what, size_t wlength)
3814 size_t newlen;
3859 size_t offset;
3943 size_t replace_len = 0;
4176 size_t block_start, block_end, block_type, block_length, i;
4178 size_t begin, end, orig_begin;
4179 size_t str_len;
4292 size_t new_char_count=char_count, new_begin=begin;
4365 size_t repl_cnt = 0;
4401 size_t repl_len = is_xhtml ? (sizeof("<br />") - 1) : (sizeof("<br>") - 1);
4448 size_t allowed_tags_len=0;
4543 size_t len = strlen(retval);
4588 size_t arglen;
4634 int php_tag_find(char *tag, size_t len, const char *set) {
4689 PHPAPI size_t php_strip_tags(char *rbuf, size_t len, uint8_t *stateptr, const char *allow, size_t a…
4715 PHPAPI size_t php_strip_tags_ex(char *rbuf, size_t len, uint8_t *stateptr, const char *allow, size_…
4720 size_t pos, i = 0;
4987 return (size_t)(rp - rbuf);
4998 size_t delim_len = 0, enc_len = 0, esc_len = 0;
5023 size_t result_len; /* Length of the resulting string */
5078 size_t retlen=0;
5079 size_t tmp = 0;
5288 size_t haystack_len, needle_len;
5310 if ((offset < 0) || ((size_t)offset > haystack_len)) {
5321 if (length < 0 || ((size_t)length > (haystack_len - offset))) {
5355 size_t num_pad_chars; /* Number of padding characters (total - input size) */
5357 size_t pad_str_len = 1;
5359 size_t i, left_pad=0, right_pad=0;
5372 if (pad_length < 0 || (size_t)pad_length <= ZSTR_LEN(input)) {
5437 size_t str_len, format_len;
5533 size_t char_list_len = 0, word_count = 0;
5612 size_t format_len = 0;
5650 ZSTR_LEN(str) = (size_t)res_len;
5666 size_t n_reg_segments;
5680 if (0 == ZSTR_LEN(str) || (size_t)split_length >= ZSTR_LEN(str)) {
5739 size_t cmp_len;
5764 if ((size_t)offset > ZSTR_LEN(s1)) {
5769 cmp_len = len ? (size_t)len : MAX(ZSTR_LEN(s2), (ZSTR_LEN(s1) - offset));
5780 static zend_string *php_utf8_encode(const char *s, size_t len)
5782 size_t pos = len;
5810 static zend_string *php_utf8_decode(const char *s, size_t len)
5812 size_t pos = 0;
5820 c = php_next_utf8_char((const unsigned char*)s, (size_t) len, &pos, &status);
5846 size_t arg_len;
5861 size_t arg_len;