1
0
mirror of https://github.com/php/php-src.git synced 2026-03-24 00:02:20 +01:00

phar: Remove duplicated error-handling code (#20137)

This is already handled by the switch below.
This commit is contained in:
Niels Dossche
2025-10-11 23:38:58 +02:00
committed by GitHub
parent b272021d0c
commit da906ee4f9

View File

@@ -703,11 +703,6 @@ PHP_METHOD(Phar, webPhar)
goto cleanup_fail;
}
if (Z_TYPE_P(rewrite_fci.retval) == IS_UNDEF || Z_TYPE(retval) == IS_UNDEF) {
zend_throw_exception_ex(phar_ce_PharException, 0, "phar error: rewrite callback must return a string or false");
goto cleanup_fail;
}
switch (Z_TYPE(retval)) {
case IS_STRING:
efree(entry);