Lines Matching refs:bucket

81 	php_stream_bucket *bucket = (php_stream_bucket *)rsrc->ptr;  in ZEND_RSRC_DTOR_FUNC()  local
82 if (bucket) { in ZEND_RSRC_DTOR_FUNC()
83 php_stream_bucket_delref(bucket TSRMLS_CC); in ZEND_RSRC_DTOR_FUNC()
84 bucket = NULL; in ZEND_RSRC_DTOR_FUNC()
244 php_stream_bucket *bucket = buckets_in->head; in userfilter_filter() local
247 while ((bucket = buckets_in->head)) { in userfilter_filter()
249 php_stream_bucket_unlink(bucket TSRMLS_CC); in userfilter_filter()
250 php_stream_bucket_delref(bucket TSRMLS_CC); in userfilter_filter()
254 php_stream_bucket *bucket = buckets_out->head; in userfilter_filter() local
255 while (bucket != NULL) { in userfilter_filter()
256 php_stream_bucket_unlink(bucket TSRMLS_CC); in userfilter_filter()
257 php_stream_bucket_delref(bucket TSRMLS_CC); in userfilter_filter()
258 bucket = buckets_out->head; in userfilter_filter()
423 php_stream_bucket *bucket; in PHP_FUNCTION() local
433 if (brigade->head && (bucket = php_stream_bucket_make_writeable(brigade->head TSRMLS_CC))) { in PHP_FUNCTION()
435 ZEND_REGISTER_RESOURCE(zbucket, bucket, le_bucket); in PHP_FUNCTION()
440 add_property_stringl(return_value, "data", bucket->buf, bucket->buflen, 1); in PHP_FUNCTION()
441 add_property_long(return_value, "datalen", bucket->buflen); in PHP_FUNCTION()
452 php_stream_bucket *bucket; in php_stream_bucket_attach() local
464 …ZEND_FETCH_RESOURCE(bucket, php_stream_bucket *, pzbucket, -1, PHP_STREAM_BUCKET_RES_NAME, le_buck… in php_stream_bucket_attach()
467 if (!bucket->own_buf) { in php_stream_bucket_attach()
468 bucket = php_stream_bucket_make_writeable(bucket TSRMLS_CC); in php_stream_bucket_attach()
470 if ((int)bucket->buflen != Z_STRLEN_PP(pzdata)) { in php_stream_bucket_attach()
471 bucket->buf = perealloc(bucket->buf, Z_STRLEN_PP(pzdata), bucket->is_persistent); in php_stream_bucket_attach()
472 bucket->buflen = Z_STRLEN_PP(pzdata); in php_stream_bucket_attach()
474 memcpy(bucket->buf, Z_STRVAL_PP(pzdata), bucket->buflen); in php_stream_bucket_attach()
478 php_stream_bucket_append(brigade, bucket TSRMLS_CC); in php_stream_bucket_attach()
480 php_stream_bucket_prepend(brigade, bucket TSRMLS_CC); in php_stream_bucket_attach()
485 if (bucket->refcount == 1) { in php_stream_bucket_attach()
486 bucket->refcount++; in php_stream_bucket_attach()
516 php_stream_bucket *bucket; in PHP_FUNCTION() local
530bucket = php_stream_bucket_new(stream, pbuffer, buffer_len, 1, php_stream_is_persistent(stream) TS… in PHP_FUNCTION()
532 if (bucket == NULL) { in PHP_FUNCTION()
537 ZEND_REGISTER_RESOURCE(zbucket, bucket, le_bucket); in PHP_FUNCTION()
542 add_property_stringl(return_value, "data", bucket->buf, bucket->buflen, 1); in PHP_FUNCTION()
543 add_property_long(return_value, "datalen", bucket->buflen); in PHP_FUNCTION()