Home
last modified time | relevance | path

Searched refs:buffer (Results 1 – 25 of 349) sorted by relevance

12345678910>>...14

/PHP-7.3/ext/zip/lib/
H A Dzip_buffer.c42 return buffer->data; in _zip_buffer_data()
57 free(buffer); in _zip_buffer_free()
64 return buffer->ok && buffer->offset == buffer->size; in _zip_buffer_eof()
73 if (!buffer->ok || buffer->offset + length < length || buffer->offset + length > buffer->size) { in _zip_buffer_get()
78 data = buffer->data + buffer->offset; in _zip_buffer_get()
140 return buffer->ok ? buffer->size - buffer->offset : 0; in _zip_buffer_left()
156 if ((buffer = (zip_buffer_t *)malloc(sizeof(*buffer))) == NULL) { in _zip_buffer_new()
163 buffer->ok = true; in _zip_buffer_new()
169 return buffer; in _zip_buffer_new()
188 return buffer; in _zip_buffer_new_from_source()
[all …]
H A Dzip_source_buffer.c43 struct buffer { struct
264 if ((buffer = malloc(sizeof(*buffer))) == NULL) { in buffer_new()
333 length = ZIP_MIN(length, buffer->size - buffer->offset); in buffer_read()
342 i = buffer->offset / buffer->fragment_size; in buffer_read()
343 fragment_offset = buffer->offset % buffer->fragment_size; in buffer_read()
386 if (buffer->offset + length > buffer->nfragments * buffer->fragment_size) { in buffer_write()
408 if ((buffer->fragments[buffer->nfragments] = malloc(buffer->fragment_size)) == NULL) { in buffer_write()
416 i = buffer->offset / buffer->fragment_size; in buffer_write()
417 fragment_offset = buffer->offset % buffer->fragment_size; in buffer_write()
430 if (buffer->offset > buffer->size) { in buffer_write()
[all …]
H A Dzip_dirent.c100 zip_buffer_t *buffer; in _zip_cdir_write() local
143 _zip_buffer_put_32(buffer, 0); in _zip_cdir_write()
144 _zip_buffer_put_32(buffer, 0); in _zip_cdir_write()
172 if (_zip_write(za, _zip_buffer_data(buffer), _zip_buffer_offset(buffer)) < 0) { in _zip_cdir_write()
177 _zip_buffer_free(buffer); in _zip_cdir_write()
309 if (buffer) { in _zip_dirent_read()
537 zip_buffer_t *buffer; in _zip_dirent_process_ef_utf_8() local
575 zip_buffer_t *buffer; in _zip_dirent_size() local
594 _zip_buffer_free(buffer); in _zip_dirent_size()
624 zip_buffer_t *buffer; in _zip_dirent_write() local
[all …]
H A Dzip_extra_field.c211 zip_buffer_t *buffer; in _zip_ef_parse() local
221 while (_zip_buffer_ok(buffer) && _zip_buffer_left(buffer) >= 4) { in _zip_ef_parse()
226 flen = _zip_buffer_get_16(buffer); in _zip_ef_parse()
251 if (!_zip_buffer_eof(buffer)) { in _zip_ef_parse()
259 _zip_buffer_free(buffer); in _zip_ef_parse()
265 _zip_buffer_free(buffer); in _zip_ef_parse()
329 if (buffer == NULL) { in _zip_ef_write()
356 _zip_buffer_free(buffer); in _zip_ef_write()
366 zip_buffer_t *buffer; in _zip_read_local_ef() local
397 _zip_buffer_free(buffer); in _zip_read_local_ef()
[all …]
H A Dzip_open.c569 zip_buffer_t *buffer; in _zip_find_central_dir() local
604 _zip_buffer_set_offset(buffer, (zip_uint64_t)(match - _zip_buffer_data(buffer))); in _zip_find_central_dir()
633 _zip_buffer_set_offset(buffer, (zip_uint64_t)(match - _zip_buffer_data(buffer))); in _zip_find_central_dir()
636 _zip_buffer_free(buffer); in _zip_find_central_dir()
687 i = _zip_buffer_get_16(buffer); in _zip_read_eocd()
772 _zip_buffer_free(buffer); in _zip_read_eocd64()
782 _zip_buffer_free(buffer); in _zip_read_eocd64()
811 i = _zip_buffer_get_64(buffer); in _zip_read_eocd64()
816 _zip_buffer_free(buffer); in _zip_read_eocd64()
824 if (!_zip_buffer_ok(buffer)) { in _zip_read_eocd64()
[all …]
/PHP-7.3/ext/mysqlnd/
H A Dmysqlnd_read_buffer.c30 return buffer->len? FALSE:TRUE; in mysqlnd_read_buffer_is_empty()
39 if (buffer->len >= count) { in mysqlnd_read_buffer_read()
40 memcpy(dest, buffer->data + buffer->offset, count); in mysqlnd_read_buffer_read()
41 buffer->offset += count; in mysqlnd_read_buffer_read()
42 buffer->len -= count; in mysqlnd_read_buffer_read()
52 return buffer->len; in mysqlnd_read_buffer_bytes_left()
59 mysqlnd_read_buffer_free(MYSQLND_READ_BUFFER ** buffer) in mysqlnd_read_buffer_free() argument
62 if (*buffer) { in mysqlnd_read_buffer_free()
63 mnd_efree((*buffer)->data); in mysqlnd_read_buffer_free()
64 mnd_efree(*buffer); in mysqlnd_read_buffer_free()
[all …]
/PHP-7.3/ext/mbstring/libmbfl/mbfl/
H A Dmbfl_memory_device.c52 device->buffer = NULL; in mbfl_memory_device_init()
77 device->buffer = tmp; in mbfl_memory_device_realloc()
93 if (device->buffer) { in mbfl_memory_device_clear()
96 device->buffer = NULL; in mbfl_memory_device_clear()
125 device->buffer = NULL; in mbfl_memory_device_result()
160 device->buffer = tmp; in mbfl_memory_device_output()
188 device->buffer = tmp; in mbfl_memory_device_output2()
218 device->buffer = tmp; in mbfl_memory_device_output4()
258 device->buffer = tmp; in mbfl_memory_device_strncat()
289 if (device->buffer) { in mbfl_wchar_device_clear()
[all …]
/PHP-7.3/ext/pcre/pcre2lib/
H A Dpcre2_ord2utf.c59 PRIV(ord2utf)(uint32_t cvalue, PCRE2_UCHAR *buffer) in PRIV()
62 (void)(buffer); in PRIV()
81 PRIV(ord2utf)(uint32_t cvalue, PCRE2_UCHAR *buffer) in PRIV()
89 buffer += i; in PRIV()
92 *buffer-- = 0x80 | (cvalue & 0x3f); in PRIV()
95 *buffer = PRIV(utf8_table2)[i] | cvalue; in PRIV()
103 *buffer = (PCRE2_UCHAR)cvalue; in PRIV()
107 *buffer++ = 0xd800 | (cvalue >> 10); in PRIV()
108 *buffer = 0xdc00 | (cvalue & 0x3ff); in PRIV()
114 *buffer = (PCRE2_UCHAR)cvalue; in PRIV()
/PHP-7.3/ext/date/lib/
H A Dparse_tz.c158 uint32_t buffer[6]; in read_32bit_header() local
160 memcpy(&buffer, *tzf, sizeof(buffer)); in read_32bit_header()
179 if (!buffer) { in read_64bit_transitions()
185 buffer[i] = timelib_conv_int64_signed(buffer[i]); in read_64bit_transitions()
187 if (i > 0 && !(buffer[i] > buffer[i - 1])) { in read_64bit_transitions()
223 if (!buffer) { in read_64bit_types()
238 …et += (int32_t) (((uint32_t) buffer[j]) << 24) + (buffer[j + 1] << 16) + (buffer[j + 2] << 8) + tz… in read_64bit_types()
276 if (!buffer) { in read_64bit_types()
291 if (!buffer) { in read_64bit_types()
347 memcpy(&buffer, *tzf, sizeof(buffer)); in read_location()
[all …]
/PHP-7.3/ext/mbstring/libmbfl/filters/
H A Dmbfilter_htmlent.c191 buffer[0] = '&'; in mbfl_filt_conv_html_dec()
197 if (buffer[1]=='#') { in mbfl_filt_conv_html_dec()
198 if (filter->status > 2 && (buffer[2] == 'x' || buffer[2] == 'X')) { in mbfl_filt_conv_html_dec()
202 int v = buffer[pos]; in mbfl_filt_conv_html_dec()
222 int v = buffer[pos]; in mbfl_filt_conv_html_dec()
247 buffer[filter->status] = 0; in mbfl_filt_conv_html_dec()
263 buffer[filter->status++] = ';'; in mbfl_filt_conv_html_dec()
264 buffer[filter->status] = 0; in mbfl_filt_conv_html_dec()
271 buffer[filter->status++] = c; in mbfl_filt_conv_html_dec()
278 buffer[filter->status] = 0; in mbfl_filt_conv_html_dec()
[all …]
/PHP-7.3/ext/standard/
H A Dpassword.c113 zend_string *buffer; in php_password_salt_to64() local
118 if (ZSTR_LEN(buffer) < out_len) { in php_password_salt_to64()
127 zend_string_free(buffer); in php_password_salt_to64()
133 zend_string_free(buffer); in php_password_salt_to64()
140 zend_string *ret, *buffer; in php_password_make_salt() local
148 if (FAILURE == php_random_bytes_silent(ZSTR_VAL(buffer), ZSTR_LEN(buffer))) { in php_password_make_salt()
155 if (php_password_salt_to64(ZSTR_VAL(buffer), ZSTR_LEN(buffer), length, ZSTR_VAL(ret)) == FAILURE) { in php_password_make_salt()
377 zend_string *buffer; in php_password_get_salt() local
382 if (!buffer) { in php_password_get_salt()
385 return buffer; in php_password_get_salt()
[all …]
H A Dformatted_print.c60 if (!*buffer || (*pos + 1) >= ZSTR_LEN(*buffer)) { in php_sprintf_appendchar()
62 *buffer = zend_string_extend(*buffer, ZSTR_LEN(*buffer) << 1, 0); in php_sprintf_appendchar()
84 *buffer, *pos, ZSTR_LEN(*buffer), add, min_width, padding, alignment)); in php_sprintf_appendstring()
93 if (!*buffer || req_size > ZSTR_LEN(*buffer)) { in php_sprintf_appendstring()
94 size_t size = ZSTR_LEN(*buffer); in php_sprintf_appendstring()
102 *buffer = zend_string_extend(*buffer, size, 0); in php_sprintf_appendstring()
137 *buffer, pos, &ZSTR_LEN(*buffer), number, width, padding, alignment)); in php_sprintf_appendint()
181 *buffer, pos, &ZSTR_LEN(*buffer), number, width, padding, alignment)); in php_sprintf_appenduint()
225 *buffer, pos, &ZSTR_LEN(*buffer), number, width, padding, alignment, fmt)); in php_sprintf_appenddouble()
318 *buffer, pos, &ZSTR_LEN(*buffer), number, width, padding, alignment, n, in php_sprintf_append2n()
[all …]
H A Dcrypt_sha256.c258 memcpy(&ctx->buffer[left_over], buffer, add); in sha256_process_bytes()
265 memcpy(ctx->buffer, &ctx->buffer[(left_over + add) & ~63], ctx->buflen); in sha256_process_bytes()
268 buffer = (const char *) buffer + add; in sha256_process_bytes()
283 sha256_process_block(memcpy(ctx->buffer, buffer, 64), 64, ctx); in sha256_process_bytes()
284 buffer = (const char *) buffer + 64; in sha256_process_bytes()
288 buffer = (const char *) buffer + (len & ~63); in sha256_process_bytes()
297 memcpy(&ctx->buffer[left_over], buffer, len); in sha256_process_bytes()
302 memcpy(ctx->buffer, &ctx->buffer[64], left_over); in sha256_process_bytes()
552 buffer = NULL; in php_sha256_crypt_r()
575 return buffer; in php_sha256_crypt_r()
[all …]
H A Diptc.c320 unsigned char *buffer, recnum, dataset; in PHP_FUNCTION() local
329 buffer = (unsigned char *)str; in PHP_FUNCTION()
332 if ((buffer[inx] == 0x1c) && ((buffer[inx+1] == 0x01) || (buffer[inx+1] == 0x02))){ in PHP_FUNCTION()
340 if (buffer[ inx++ ] != 0x1c) { in PHP_FUNCTION()
347 dataset = buffer[ inx++ ]; in PHP_FUNCTION()
348 recnum = buffer[ inx++ ]; in PHP_FUNCTION()
350 if (buffer[ inx ] & (unsigned char) 0x80) { /* long tag */ in PHP_FUNCTION()
354 len = (((zend_long) buffer[ inx + 2 ]) << 24) + (((zend_long) buffer[ inx + 3 ]) << 16) + in PHP_FUNCTION()
355 (((zend_long) buffer[ inx + 4 ]) << 8) + (((zend_long) buffer[ inx + 5 ])); in PHP_FUNCTION()
358 len = (((unsigned short) buffer[ inx ])<<8) | (unsigned short)buffer[ inx+1 ]; in PHP_FUNCTION()
[all …]
H A Dcrypt_sha512.c285 memcpy(&ctx->buffer[left_over], buffer, add); in sha512_process_bytes()
293 memcpy(ctx->buffer, &ctx->buffer[(left_over + add) & ~127], in sha512_process_bytes()
297 buffer = (const char *) buffer + add; in sha512_process_bytes()
313 sha512_process_block(memcpy(ctx->buffer, buffer, 128), 128, ctx); in sha512_process_bytes()
314 buffer = (const char *) buffer + 128; in sha512_process_bytes()
321 buffer = (const char *) buffer + (len & ~127); in sha512_process_bytes()
330 memcpy(&ctx->buffer[left_over], buffer, len); in sha512_process_bytes()
335 memcpy(ctx->buffer, &ctx->buffer[128], left_over); in sha512_process_bytes()
599 buffer = NULL; in php_sha512_crypt_r()
622 return buffer; in php_sha512_crypt_r()
[all …]
/PHP-7.3/ext/hash/
H A Dhash_whirlpool.c46 unsigned char *buffer = context->buffer.data; in WhirlpoolTransform() local
51 for (i = 0; i < 8; i++, buffer += 8) { in WhirlpoolTransform()
280 unsigned char *buffer = context->buffer.data; in PHP_WHIRLPOOLUpdate() local
282 int bufferBits = context->buffer.bits; in PHP_WHIRLPOOLUpdate()
283 int bufferPos = context->buffer.pos; in PHP_WHIRLPOOLUpdate()
338 buffer[bufferPos] |= b >> bufferRem; in PHP_WHIRLPOOLUpdate()
371 context->buffer.bits = bufferBits; in PHP_WHIRLPOOLUpdate()
372 context->buffer.pos = bufferPos; in PHP_WHIRLPOOLUpdate()
378 unsigned char *buffer = context->buffer.data; in PHP_WHIRLPOOLFinal() local
380 int bufferBits = context->buffer.bits; in PHP_WHIRLPOOLFinal()
[all …]
H A Dhash_tiger.c141 context->buffer[context->length++] = 0x1; in TigerFinalize()
143 memset(&context->buffer[context->length], 0, 8-context->length%8); in TigerFinalize()
150 memset(context->buffer, 0, 56); in TigerFinalize()
156 memcpy(&context->buffer[56], &context->passed, sizeof(uint64_t)); in TigerFinalize()
158 context->buffer[56] = (unsigned char) (context->passed & 0xff); in TigerFinalize()
199 memcpy(&context->buffer[context->length], input, len); in PHP_TIGERUpdate()
206 memcpy(&context->buffer[context->length], input, i); in PHP_TIGERUpdate()
208 ZEND_SECURE_ZERO(context->buffer, 64); in PHP_TIGERUpdate()
213 memcpy(context->buffer, &input[i], 64); in PHP_TIGERUpdate()
217 ZEND_SECURE_ZERO(&context->buffer[r], 64-r); in PHP_TIGERUpdate()
[all …]
/PHP-7.3/tests/output/
H A Dob_start_basic_unerasable_005.phpt2 ob_start(): Ensure unerasable buffer cannot be flushed by ob_flush()
13 echo "Attempt to flush unerasable buffer - should fail... ";
15 // Check content of buffer after flush - if flush failed it should still contain the string above.
19 [callback:1]Attempt to flush unerasable buffer - should fail...
20 Notice: ob_flush(): failed to flush buffer of callback (0) in %s on line 11
22 string(%d) "Attempt to flush unerasable buffer - should fail...
23 Notice: ob_flush(): failed to flush buffer of callback (0) in %s on line 11
H A Dbug60768.phpt2 Bug #60768 Output buffer not discarded
8 ob_start(function($buffer) use (&$storage) { $storage .= $buffer; }, 20);
10 echo str_repeat("0", 20); // fill in the buffer
13 echo str_pad($i, 9, ' ', STR_PAD_LEFT) . "\n"; // full buffer dumped every time
H A Dob_start_basic_unerasable_003.phpt2 ob_start(): Ensure unerasable buffer cannot be accessed or erased by ob_get_clean().
13 echo "This call will obtain the content, but will not clean the buffer.";
18 [callback:1]This call will obtain the content, but will not clean the buffer.
19 Notice: ob_get_clean(): failed to discard buffer of callback (0) in %s on line 11
21 Notice: ob_get_clean(): failed to delete buffer of callback (0) in %s on line 11
22 string(65) "This call will obtain the content, but will not clean the buffer."
H A Dob_start_basic_unerasable_004.phpt2 ob_start(): Ensure unerasable buffer cannot be accessed or flushed by ob_get_flush().
13 echo "This call will obtain the content, but will not flush the buffer.";
18 [callback:1]This call will obtain the content, but will not flush the buffer.
19 Notice: ob_get_flush(): failed to send buffer of callback (0) in %s on line 11
21 Notice: ob_get_flush(): failed to delete buffer of callback (0) in %s on line 11
22 string(65) "This call will obtain the content, but will not flush the buffer."
H A Dob_flush_basic_001.phpt6 …Description: Flush (send) contents of the output buffer. The last buffer content is sent to next b…
21 echo "Ensure the buffer is still active after the flush.\n";
33 Notice: ob_flush(): failed to flush buffer. No buffer to flush in %s on line 12
37 Ensure the buffer is still active after the flush.
H A Dbug46897.phpt13 echo "Attempt to flush unerasable buffer - should fail...";
15 // Check content of buffer after flush - if flush failed it should still contain the string above.
20 [callback:1]Attempt to flush unerasable buffer - should fail...
21 Notice: ob_flush(): failed to flush buffer of callback (0) in %s on line %d
23 string(%d) "Attempt to flush unerasable buffer - should fail...
24 Notice: ob_flush(): failed to flush buffer of callback (0) in %s on line %d
H A Dob_end_flush_basic_001.phpt6 * Description: Flush (send) the output buffer, and delete current output buffer
33 Notice: ob_end_flush(): failed to delete and flush buffer. No buffer to delete or flush in %s on li…
39 Notice: ob_end_flush(): failed to delete and flush buffer. No buffer to delete or flush in %s on li…
/PHP-7.3/ext/standard/tests/general_functions/
H A Dob_get_flush_error.phpt8 …* Description: Get current buffer contents, flush (send) the output buffer, and delete current out…
30 Notice: ob_get_flush(): failed to delete and flush buffer. No buffer to delete or flush in %s on li…

Completed in 70 milliseconds

12345678910>>...14