Lines Matching refs:maxlen

890 PHPAPI char *_php_stream_get_line(php_stream *stream, char *buf, size_t maxlen,  in _php_stream_get_line()  argument
901 } else if (maxlen == 0) { in _php_stream_get_line()
949 if (cpysz >= maxlen - 1) { in _php_stream_get_line()
950 cpysz = maxlen - 1; in _php_stream_get_line()
960 maxlen -= cpysz; in _php_stream_get_line()
975 toread = maxlen - 1; in _php_stream_get_line()
1008 size_t maxlen, in _php_stream_search_delim() argument
1016 seek_len = MIN(STREAM_BUFFERED_AMOUNT(stream), maxlen); in _php_stream_search_delim()
1031 PHPAPI zend_string *php_stream_get_record(php_stream *stream, size_t maxlen, const char *delim, siz… in php_stream_get_record() argument
1039 if (maxlen == 0) { in php_stream_get_record()
1045 stream, maxlen, 0, delim, delim_len); in php_stream_get_record()
1050 while (!found_delim && buffered_len < maxlen) { in php_stream_get_record()
1054 to_read_now = MIN(maxlen - buffered_len, stream->chunk_size); in php_stream_get_record()
1074 stream, maxlen, in php_stream_get_record()
1088 } else if (!has_delim && STREAM_BUFFERED_AMOUNT(stream) >= maxlen) { in php_stream_get_record()
1089 tent_ret_len = maxlen; in php_stream_get_record()
1095 if (STREAM_BUFFERED_AMOUNT(stream) < maxlen && !stream->eof) { in php_stream_get_record()
1102 tent_ret_len = MIN(STREAM_BUFFERED_AMOUNT(stream), maxlen); in php_stream_get_record()
1462 PHPAPI zend_string *_php_stream_copy_to_mem(php_stream *src, size_t maxlen, int persistent STREAMS_… in _php_stream_copy_to_mem() argument
1472 if (maxlen == 0) { in _php_stream_copy_to_mem()
1476 if (maxlen == PHP_STREAM_COPY_ALL) { in _php_stream_copy_to_mem()
1477 maxlen = 0; in _php_stream_copy_to_mem()
1480 if (maxlen > 0) { in _php_stream_copy_to_mem()
1481 result = zend_string_alloc(maxlen, persistent); in _php_stream_copy_to_mem()
1483 while ((len < maxlen) && !php_stream_eof(src)) { in _php_stream_copy_to_mem()
1484 ret = php_stream_read(src, ptr, maxlen - len); in _php_stream_copy_to_mem()
1497 if (len < maxlen / 2) { in _php_stream_copy_to_mem()
1545 PHPAPI int _php_stream_copy_to_stream_ex(php_stream *src, php_stream *dest, size_t maxlen, size_t *… in _php_stream_copy_to_stream_ex() argument
1556 if (maxlen == 0) { in _php_stream_copy_to_stream_ex()
1561 if (maxlen == PHP_STREAM_COPY_ALL) { in _php_stream_copy_to_stream_ex()
1562 maxlen = 0; in _php_stream_copy_to_stream_ex()
1569 size_t chunk_size = (maxlen == 0 || maxlen > PHP_STREAM_MMAP_MAX) ? PHP_STREAM_MMAP_MAX : maxlen; in _php_stream_copy_to_stream_ex()
1601 if (maxlen != 0) { in _php_stream_copy_to_stream_ex()
1602 maxlen -= mapped; in _php_stream_copy_to_stream_ex()
1603 if (maxlen == 0) { in _php_stream_copy_to_stream_ex()
1616 if (maxlen && (maxlen - haveread) < readchunk) { in _php_stream_copy_to_stream_ex()
1617 readchunk = maxlen - haveread; in _php_stream_copy_to_stream_ex()
1641 if (maxlen && maxlen == haveread) { in _php_stream_copy_to_stream_ex()
1654 PHPAPI size_t _php_stream_copy_to_stream(php_stream *src, php_stream *dest, size_t maxlen STREAMS_D… in _php_stream_copy_to_stream()
1657 int ret = _php_stream_copy_to_stream_ex(src, dest, maxlen, &len STREAMS_REL_CC); in _php_stream_copy_to_stream()
1658 if (ret == SUCCESS && len == 0 && maxlen != 0) { in _php_stream_copy_to_stream()