Skip to content

Commit 152c877

Browse files
committed
* Fixed bugs in the Timeout class.
1 parent 9537c42 commit 152c877

File tree

1 file changed

+5
-3
lines changed

1 file changed

+5
-3
lines changed

Zend/zend_async_API.h

Lines changed: 5 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -135,7 +135,7 @@ typedef void (*zend_async_event_callback_fn)
135135
typedef void (*zend_async_event_callback_dispose_fn)(zend_async_event_callback_t *callback, zend_async_event_t * event);
136136
typedef void (*zend_async_event_add_callback_t)(zend_async_event_t *event, zend_async_event_callback_t *callback);
137137
typedef void (*zend_async_event_del_callback_t)(zend_async_event_t *event, zend_async_event_callback_t *callback);
138-
typedef bool (*zend_async_event_callbacks_notify_t)(zend_async_event_t *event, void *result, zend_object *exception);
138+
typedef bool (*zend_async_event_callbacks_notify_t)(zend_async_event_t *event, void **result, zend_object **exception);
139139
typedef void (*zend_async_event_start_t) (zend_async_event_t *event);
140140
typedef void (*zend_async_event_stop_t) (zend_async_event_t *event);
141141
typedef void (*zend_async_event_dispose_t) (zend_async_event_t *event);
@@ -411,8 +411,10 @@ static zend_always_inline void
411411
zend_async_callbacks_notify(zend_async_event_t *event, void *result, zend_object *exception)
412412
{
413413
// If pre-notify returns false, we stop notifying callbacks
414-
if (event->before_notify != NULL && false == event->before_notify(event, result, exception)) {
415-
return;
414+
if (event->before_notify != NULL) {
415+
if (false == event->before_notify(event, &result, &exception)) {
416+
return;
417+
}
416418
}
417419

418420
if (event->callbacks.data == NULL) {

0 commit comments

Comments
 (0)