Skip to content

Commit 774ccb5

Browse files
committed
Fix error on Windows
1 parent be9d4a5 commit 774ccb5

File tree

3 files changed

+5
-4
lines changed

3 files changed

+5
-4
lines changed

Zend/zend_interfaces.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -198,7 +198,8 @@ ZEND_API HashTable *zend_user_it_get_gc(zend_object_iterator *_iter, zval **tabl
198198

199199
static const zend_object_iterator_funcs zend_interface_iterator_funcs_iterator = {
200200
zend_user_it_dtor,
201-
zend_user_it_valid,
201+
// FIXME: Adjust the actual function prototype in zend_object_iterator_funcs
202+
(int (*)(zend_object_iterator *iter)) zend_user_it_valid,
202203
zend_user_it_get_current_data,
203204
zend_user_it_get_current_key,
204205
zend_user_it_move_forward,

Zend/zend_virtual_cwd.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -260,7 +260,7 @@ extern void virtual_cwd_main_cwd_init(uint8_t);
260260
#define VCWD_OPEN_MODE(path, flags, mode) virtual_open(path, flags, mode)
261261
#define VCWD_CREAT(path, mode) virtual_creat(path, mode)
262262
#define VCWD_CHDIR(path) virtual_chdir(path)
263-
#define VCWD_CHDIR_FILE(path) virtual_chdir_file(path, virtual_chdir)
263+
#define VCWD_CHDIR_FILE(path) virtual_chdir_file(path, (int (*)(const char *path)) virtual_chdir)
264264
#define VCWD_GETWD(buf)
265265
#define VCWD_REALPATH(path, real_path) virtual_realpath(path, real_path)
266266
#define VCWD_RENAME(oldname, newname) virtual_rename(oldname, newname)

ext/session/session.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -2888,7 +2888,7 @@ static PHP_MINIT_FUNCTION(session) /* {{{ */
28882888
PHP_MINIT(ps_mm) (INIT_FUNC_ARGS_PASSTHRU);
28892889
#endif
28902890
php_session_rfc1867_orig_callback = php_rfc1867_callback;
2891-
php_rfc1867_callback = php_session_rfc1867_callback;
2891+
php_rfc1867_callback = (int (*)(unsigned int event, void *event_data, void **extra)) php_session_rfc1867_callback;
28922892

28932893
/* Register interfaces */
28942894
php_session_iface_entry = register_class_SessionHandlerInterface();
@@ -2916,7 +2916,7 @@ static PHP_MSHUTDOWN_FUNCTION(session) /* {{{ */
29162916

29172917
/* reset rfc1867 callbacks */
29182918
php_session_rfc1867_orig_callback = NULL;
2919-
if (php_rfc1867_callback == php_session_rfc1867_callback) {
2919+
if (php_rfc1867_callback == (int (*)(unsigned int event, void *event_data, void **extra)) php_session_rfc1867_callback) {
29202920
php_rfc1867_callback = NULL;
29212921
}
29222922

0 commit comments

Comments
 (0)