@@ -389,7 +389,7 @@ static void filter_item_dtor(zval *zv)
389389 efree (fdat );
390390}
391391
392- /* {{{ proto object|false stream_bucket_make_writeable(resource brigade)
392+ /* {{{ proto object|null stream_bucket_make_writeable(resource brigade)
393393 Return a bucket object from the brigade for operating on */
394394PHP_FUNCTION (stream_bucket_make_writeable )
395395{
@@ -434,8 +434,8 @@ static void php_stream_bucket_attach(int append, INTERNAL_FUNCTION_PARAMETERS)
434434 ZEND_PARSE_PARAMETERS_END ();
435435
436436 if (NULL == (pzbucket = zend_hash_str_find (Z_OBJPROP_P (zobject ), "bucket" , sizeof ("bucket" )- 1 ))) {
437- php_error_docref ( NULL , E_WARNING , "Object has no bucket property" );
438- RETURN_FALSE ;
437+ zend_value_error ( "Object has no bucket property" );
438+ return ;
439439 }
440440
441441 if ((brigade = (php_stream_bucket_brigade * )zend_fetch_resource (
@@ -505,7 +505,6 @@ PHP_FUNCTION(stream_bucket_new)
505505 ZEND_PARSE_PARAMETERS_END ();
506506
507507 php_stream_from_zval (stream , zstream );
508-
509508 pbuffer = pemalloc (buffer_len , php_stream_is_persistent (stream ));
510509
511510 memcpy (pbuffer , buffer , buffer_len );
@@ -564,15 +563,13 @@ PHP_FUNCTION(stream_filter_register)
564563 Z_PARAM_STR (classname )
565564 ZEND_PARSE_PARAMETERS_END ();
566565
567- RETVAL_FALSE ;
568-
569566 if (!ZSTR_LEN (filtername )) {
570- php_error_docref ( NULL , E_WARNING , "Filter name cannot be empty" );
567+ zend_value_error ( "Filter name cannot be empty" );
571568 return ;
572569 }
573570
574571 if (!ZSTR_LEN (classname )) {
575- php_error_docref ( NULL , E_WARNING , "Class name cannot be empty" );
572+ zend_value_error ( "Class name cannot be empty" );
576573 return ;
577574 }
578575
@@ -590,6 +587,7 @@ PHP_FUNCTION(stream_filter_register)
590587 } else {
591588 zend_string_release_ex (classname , 0 );
592589 efree (fdat );
590+ RETVAL_FALSE ;
593591 }
594592}
595593/* }}} */
0 commit comments