/php-src/main/streams/ |
H A D | streams.c | 991 maxlen -= cpysz; in _php_stream_get_line() 1070 if (maxlen == 0) { in php_stream_get_record() 1105 stream, maxlen, in php_stream_get_record() 1526 if (maxlen == 0) { in _php_stream_copy_to_mem() 1531 maxlen = 0; in _php_stream_copy_to_mem() 1534 if (maxlen > 0 && maxlen < 4 * CHUNK_SIZE) { in _php_stream_copy_to_mem() 1569 if (maxlen > 0 && buflen > maxlen) { in _php_stream_copy_to_mem() 1586 if (maxlen > 0 && buflen + step > maxlen) { in _php_stream_copy_to_mem() 1701 maxlen = 0; in _php_stream_copy_to_stream_ex() 1770 if (maxlen && (maxlen - haveread) < readchunk) { in _php_stream_copy_to_stream_ex() [all …]
|
/php-src/main/ |
H A D | php_streams.h | 62 #define php_stream_copy_to_mem_rel(src, maxlen, persistent) _php_stream_copy_to_mem((src), (buf), (… argument 353 PHPAPI char *_php_stream_get_line(php_stream *stream, char *buf, size_t maxlen, size_t *returned_le… 354 #define php_stream_gets(stream, buf, maxlen) _php_stream_get_line((stream), (buf), (maxlen), NULL) argument 356 #define php_stream_get_line(stream, buf, maxlen, retlen) _php_stream_get_line((stream), (buf), (max… argument 357 PHPAPI zend_string *php_stream_get_record(php_stream *stream, size_t maxlen, const char *delim, siz… 480 PHPAPI size_t _php_stream_copy_to_stream(php_stream *src, php_stream *dest, size_t maxlen STREAMS_D… 481 #define php_stream_copy_to_stream(src, dest, maxlen) _php_stream_copy_to_stream((src), (dest), (max… argument 482 PHPAPI zend_result _php_stream_copy_to_stream_ex(php_stream *src, php_stream *dest, size_t maxlen, … 483 …ine php_stream_copy_to_stream_ex(src, dest, maxlen, len) _php_stream_copy_to_stream_ex((src), (des… argument 488 PHPAPI zend_string *_php_stream_copy_to_mem(php_stream *src, size_t maxlen, int persistent STREAMS_… [all …]
|
/php-src/ext/standard/tests/file/ |
H A D | file_get_contents_file_put_contents_error.phpt | 13 echo "\n-- Testing for invalid negative maxlen values --\n"; 36 -- Testing for invalid negative maxlen values --
|
H A D | file_get_contents_error.phpt | 19 echo "\n-- Testing for invalid negative maxlen values --\n"; 49 -- Testing for invalid negative maxlen values --
|
H A D | bug38086.phpt | 2 Bug #38086 (stream_copy_to_stream() returns 0 when maxlen is bigger than the actual length)
|
/php-src/ext/standard/tests/streams/ |
H A D | bug60455_04.phpt | 2 Bug #60455: stream_get_line and 1-line with maxlen size followed by 0-length
|
/php-src/sapi/phpdbg/ |
H A D | phpdbg_utils.c | 660 char *phpdbg_short_zval_print(zval *zv, int maxlen) /* {{{ */ in phpdbg_short_zval_print() argument 704 ZSTR_LEN(str) <= maxlen - 2 ? (int) ZSTR_LEN(str) : (maxlen - 3), in phpdbg_short_zval_print() 705 ZSTR_VAL(str), ZSTR_LEN(str) <= maxlen - 2 ? 0 : '+'); in phpdbg_short_zval_print() 717 ZSTR_LEN(str) <= maxlen ? (int) ZSTR_LEN(str) : maxlen - 1, in phpdbg_short_zval_print() 718 ZSTR_VAL(str), ZSTR_LEN(str) <= maxlen ? 0 : '+'); in phpdbg_short_zval_print()
|
H A D | phpdbg_utils.h | 94 char *phpdbg_short_zval_print(zval *zv, int maxlen);
|
/php-src/ext/standard/ |
H A D | html.c | 1097 size_t cursor, maxlen, len; in php_escape_html_entities_ex() local 1139 maxlen = 128; in php_escape_html_entities_ex() 1141 maxlen = zend_safe_addmult(oldlen, 2, 0, "html_entities"); in php_escape_html_entities_ex() 1144 replaced = zend_string_alloc(maxlen, 0); in php_escape_html_entities_ex() 1156 if (len > maxlen - 40) { /* maxlen can never be smaller than 128 */ in php_escape_html_entities_ex() 1157 replaced = zend_string_safe_realloc(replaced, maxlen, 1, 128, 0); in php_escape_html_entities_ex() 1158 maxlen += 128; in php_escape_html_entities_ex() 1287 if (maxlen - len < ent_len + 2 /* & and ; */) { in php_escape_html_entities_ex() 1289 replaced = zend_string_safe_realloc(replaced, maxlen, 1, ent_len + 128, 0); in php_escape_html_entities_ex() 1290 maxlen += ent_len + 128; in php_escape_html_entities_ex()
|
H A D | streamsfuncs.c | 445 zend_long maxlen, desiredpos = -1L; in PHP_FUNCTION() local 452 Z_PARAM_LONG_OR_NULL(maxlen, maxlen_is_null) in PHP_FUNCTION() 457 maxlen = (ssize_t) PHP_STREAM_COPY_ALL; in PHP_FUNCTION() 458 } else if (maxlen < 0 && maxlen != (ssize_t)PHP_STREAM_COPY_ALL) { in PHP_FUNCTION() 485 if ((contents = php_stream_copy_to_mem(stream, maxlen, 0))) { in PHP_FUNCTION() 498 zend_long maxlen, pos = 0; in PHP_FUNCTION() local 507 Z_PARAM_LONG_OR_NULL(maxlen, maxlen_is_null) in PHP_FUNCTION() 512 maxlen = PHP_STREAM_COPY_ALL; in PHP_FUNCTION() 523 ret = php_stream_copy_to_stream_ex(src, dest, maxlen, &len); in PHP_FUNCTION()
|
H A D | var_unserializer.re | 1025 size_t len, maxlen; 1029 maxlen = max - YYCURSOR; 1030 if (maxlen < len) { 1062 size_t len, maxlen; 1066 maxlen = max - YYCURSOR; 1067 if (maxlen < len) { 1132 size_t len, maxlen; 1151 maxlen = max - YYCURSOR; 1152 if (maxlen < len || len == 0) { 1353 size_t maxlen = max - YYCURSOR; [all …]
|
H A D | file.c | 389 zend_long maxlen; in PHP_FUNCTION() local 402 Z_PARAM_LONG_OR_NULL(maxlen, maxlen_is_null) in PHP_FUNCTION() 406 maxlen = (ssize_t) PHP_STREAM_COPY_ALL; in PHP_FUNCTION() 407 } else if (maxlen < 0) { in PHP_FUNCTION() 433 if ((contents = php_stream_copy_to_mem(stream, maxlen, 0)) != NULL) { in PHP_FUNCTION() 997 zend_long maxlen = 0; in PHP_FUNCTION() local 1005 Z_PARAM_LONG_OR_NULL(maxlen, maxlen_is_null) in PHP_FUNCTION() 1010 } else if (maxlen <= 0) { in PHP_FUNCTION() 1013 num_bytes = MIN((size_t) maxlen, inputlen); in PHP_FUNCTION()
|
H A D | array.c | 6755 uint32_t k, maxlen = 0; local 6772 maxlen = zend_hash_num_elements(Z_ARRVAL(arrays[0])); 6775 if (!ZEND_FCI_INITIALIZED(fci) || !maxlen) { 6780 array_init_size(return_value, maxlen); 6810 if (zend_hash_num_elements(Z_ARRVAL(arrays[i])) > maxlen) { 6811 maxlen = zend_hash_num_elements(Z_ARRVAL(arrays[i])); 6815 array_init_size(return_value, maxlen); 6821 for (k = 0; k < maxlen; k++) { 6865 for (k = 0; k < maxlen; k++) {
|
H A D | string.c | 2908 size_t maxlen = 0; local 2933 if (len > maxlen) { 2934 maxlen = len; 2958 if (len > maxlen) { 2959 maxlen = len; 2983 if (UNEXPECTED(minlen > maxlen)) { 2996 len = maxlen;
|
/php-src/ |
H A D | .gdbinit | 527 set $maxlen = $arg2 529 set $maxlen = 256 533 while $tmp < $arg1 && $tmp < $maxlen 606 set $maxlen = $arg1 608 set $maxlen = $zstr->len 611 ____print_str (char*)$zstr->val $zstr->len $maxlen
|
/php-src/docs-old/ |
H A D | streams.md | 31 PHPAPI char *php_stream_gets(php_stream * stream, char *buf, size_t maxlen); 108 php_stream *dest, size_t maxlen); 112 `PHP_STREAM_COPY_ALL` as the maxlen parameter, otherwise maxlen indicates the 121 size_t maxlen, int persistent); 125 will be maxlen bytes in length, or will be the entire length of the data 126 remaining on the stream if you set maxlen to `PHP_STREAM_COPY_ALL`. The buffer
|
/php-src/ext/phar/ |
H A D | func_interceptors.c | 164 zend_long maxlen; in PHP_FUNCTION() local 178 …M_ARGS(), "P|br!ll!", &filename, &use_include_path, &zcontext, &offset, &maxlen, &maxlen_is_null) … in PHP_FUNCTION() 183 maxlen = (ssize_t) PHP_STREAM_COPY_ALL; in PHP_FUNCTION() 184 } else if (maxlen < 0) { in PHP_FUNCTION() 216 contents = php_stream_copy_to_mem(stream, maxlen, 0); in PHP_FUNCTION()
|
/php-src/Zend/ |
H A D | zend_operators.h | 280 static zend_always_inline size_t zend_strnlen(const char* s, size_t maxlen) in zend_strnlen() argument 283 return strnlen(s, maxlen); in zend_strnlen() 285 const char *p = (const char *)memchr(s, '\0', maxlen); in zend_strnlen() 286 return p ? p-s : maxlen; in zend_strnlen()
|
/php-src/ext/pdo_sqlite/ |
H A D | sqlite_statement.c | 249 stmt->columns[colno].maxlen = SIZE_MAX; in pdo_sqlite_stmt_describe()
|
/php-src/ext/pdo_dblib/ |
H A D | dblib_stmt.c | 252 col->maxlen = dbcollen(H->link, colno+1); in pdo_dblib_stmt_describe()
|
/php-src/ext/pdo/ |
H A D | php_pdo_driver.h | 533 size_t maxlen; member
|
/php-src/ext/fileinfo/libmagic/ |
H A D | softmagic.c | 1993 file_strncmp(const char *s1, const char *s2, size_t len, size_t maxlen, in file_strncmp() argument 2006 const unsigned char *eb = b + (ws ? maxlen : len); in file_strncmp() 2072 file_strncmp16(const char *a, const char *b, size_t len, size_t maxlen, in file_strncmp16() argument 2081 return file_strncmp(a, b, len, maxlen, flags); in file_strncmp16()
|
/php-src/ext/sockets/ |
H A D | sockets.c | 303 static int php_read(php_socket *sock, void *buf, size_t maxlen, int flags) argument 324 while (*t != '\n' && *t != '\r' && n < maxlen) { 343 if (n < maxlen) { 354 if (n < maxlen) {
|
/php-src/ext/pdo_odbc/ |
H A D | odbc_stmt.c | 611 col->maxlen = S->cols[colno].datalen = colsize; in odbc_stmt_describe()
|
/php-src/ext/pdo_mysql/ |
H A D | mysql_statement.c | 662 cols[i].maxlen = S->fields[i].length; in pdo_mysql_stmt_describe()
|