diff --git a/ext/phar/phar_object.c b/ext/phar/phar_object.c index 2225d21d187..1da17b247b2 100644 --- a/ext/phar/phar_object.c +++ b/ext/phar/phar_object.c @@ -1500,7 +1500,7 @@ static int phar_build(zend_object_iterator *iter, void *puser) /* {{{ */ } ZEND_FALLTHROUGH; default: - zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0, "Iterator %s returned an invalid value (must return a string)", ZSTR_VAL(ce->name)); + zend_throw_exception_ex(spl_ce_UnexpectedValueException, 0, "Iterator %s returned an invalid value (must return a string, a stream, or an SplFileInfo object)", ZSTR_VAL(ce->name)); return ZEND_HASH_APPLY_STOP; } diff --git a/ext/phar/tests/phar_buildfromiterator5.phpt b/ext/phar/tests/phar_buildfromiterator5.phpt index 1e937fe4e8d..2ddf1c282ec 100644 --- a/ext/phar/tests/phar_buildfromiterator5.phpt +++ b/ext/phar/tests/phar_buildfromiterator5.phpt @@ -49,4 +49,4 @@ rewind valid current %s(24) "UnexpectedValueException" -Iterator myIterator returned an invalid value (must return a string) +Iterator myIterator returned an invalid value (must return a string, a stream, or an SplFileInfo object) diff --git a/ext/phar/tests/tar/phar_buildfromiterator5.phpt b/ext/phar/tests/tar/phar_buildfromiterator5.phpt index 27d9dc323b4..6a81c1df65d 100644 --- a/ext/phar/tests/tar/phar_buildfromiterator5.phpt +++ b/ext/phar/tests/tar/phar_buildfromiterator5.phpt @@ -49,4 +49,4 @@ rewind valid current %s(24) "UnexpectedValueException" -Iterator myIterator returned an invalid value (must return a string) +Iterator myIterator returned an invalid value (must return a string, a stream, or an SplFileInfo object) diff --git a/ext/phar/tests/zip/phar_buildfromiterator5.phpt b/ext/phar/tests/zip/phar_buildfromiterator5.phpt index fb34f090954..3c587dfc9c8 100644 --- a/ext/phar/tests/zip/phar_buildfromiterator5.phpt +++ b/ext/phar/tests/zip/phar_buildfromiterator5.phpt @@ -49,4 +49,4 @@ rewind valid current %s(24) "UnexpectedValueException" -Iterator myIterator returned an invalid value (must return a string) +Iterator myIterator returned an invalid value (must return a string, a stream, or an SplFileInfo object)