This was a warning
This is now a error using GCC 14 (on Fedora 40)
/builddir/build/BUILD/php82-php-pecl-ice-1.10.1/NTS/kernel/file.c:71:23: error: passing argument 1 of 'zval_ptr_dtor' from incompatible pointer type [-Wincompatible-pointer-types]
71
zval_ptr_dtor(file);
^~~~
zend_string {aka struct _zend_string }
In file included from /opt/remi/php82/root/usr/include/php/Zend/zend.h:36,
from /opt/remi/php82/root/usr/include/php/main/php.h:31,
from /builddir/build/BUILD/php82-php-pecl-ice-1.10.1/NTS/kernel/file.c:16:
/opt/remi/php82/root/usr/include/php/Zend/zend_variables.h:79:35: note: expected 'zval ' {aka 'struct _zval_struct '} but argument is of type 'zend_string ' {aka 'struct _zend_string '}
79
ZEND_API void zval_ptr_dtor(zval *zval_ptr);
~~^~~~
/builddir/build/BUILD/php82-php-pecl-ice-1.10.1/NTS/kernel/file.c: In function 'zephir_fclose':
/builddir/build/BUILD/php82-php-pecl-ice-1.10.1/NTS/kernel/file.c:179:53: warning: format '%d' expects argument of type 'int', but argument 4 has type 'zend_long' {aka 'long int'} [-Wformat=]
179
php_error_docref(NULL, E_WARNING, "%d is not a valid stream resource", stream->res->handle);
~^ ~~~~~~~
int zend_long {aka long int}
%ld
/builddir/build/BUILD/php82-php-pecl-ice-1.10.1/NTS/kernel/file.c: In function 'zephir_filemtime':
/builddir/build/BUILD/php82-php-pecl-ice-1.10.1/NTS/kernel/file.c:300:31: error: passing argument 1 of 'zval_ptr_dtor' from incompatible pointer type [-Wincompatible-pointer-types]
300
zval_ptr_dtor(file);
^~~~
zend_string {aka struct _zend_string }
/opt/remi/php82/root/usr/include/php/Zend/zend_variables.h:79:35: note: expected 'zval ' {aka 'struct _zval_struct '} but argument is of type 'zend_string ' {aka 'struct _zend_string '}
79 | ZEND_API void zval_ptr_dtor(zval *zval_ptr);
| ~~^~~~
This was a warning This is now a error using GCC 14 (on Fedora 40)
~~^~~~ /builddir/build/BUILD/php82-php-pecl-ice-1.10.1/NTS/kernel/file.c: In function 'zephir_fclose': /builddir/build/BUILD/php82-php-pecl-ice-1.10.1/NTS/kernel/file.c:179:53: warning: format '%d' expects argument of type 'int', but argument 4 has type 'zend_long' {aka 'long int'} [-Wformat=] 179~~~~~~~/opt/remi/php82/root/usr/include/php/Zend/zend_variables.h:79:35: note: expected 'zval ' {aka 'struct _zval_struct '} but argument is of type 'zend_string ' {aka 'struct _zend_string '} 79 | ZEND_API void zval_ptr_dtor(zval *zval_ptr); |
~~^~~~