Skip to content

Commit 78c5bac

Browse files
committed
Use RETURN_COPY()
1 parent 8d861b2 commit 78c5bac

File tree

1 file changed

+2
-2
lines changed

1 file changed

+2
-2
lines changed

Zend/zend_builtin_functions.c

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1328,7 +1328,7 @@ ZEND_FUNCTION(get_error_handler)
13281328
ZEND_PARSE_PARAMETERS_NONE();
13291329

13301330
if (Z_TYPE(EG(user_error_handler)) != IS_UNDEF) {
1331-
RETURN_ZVAL(&EG(user_error_handler), 1, 0);
1331+
RETURN_COPY(&EG(user_error_handler));
13321332
}
13331333
}
13341334

@@ -1383,7 +1383,7 @@ ZEND_FUNCTION(get_exception_handler)
13831383
ZEND_PARSE_PARAMETERS_NONE();
13841384

13851385
if (Z_TYPE(EG(user_exception_handler)) != IS_UNDEF) {
1386-
RETURN_ZVAL(&EG(user_exception_handler), 1, 0);
1386+
RETURN_COPY(&EG(user_exception_handler));
13871387
}
13881388
}
13891389

0 commit comments

Comments
 (0)