diff options
| author | jvoisin | 2018-01-19 14:12:18 +0100 |
|---|---|---|
| committer | jvoisin | 2018-01-19 14:12:18 +0100 |
| commit | c166a9ff5b7213276a3c14e00a9ba7f0ede98186 (patch) | |
| tree | 72436b40fab7992d543c5401624e52a96d0479d0 /src/sp_execute.c | |
| parent | 093b89fb9e95012ab950febc6c51360e6a2d189a (diff) | |
Fix a possible double-execute
Some extensions might hook `zend_execute_internal` for various reason,
although few are doing it. We're not supposed to call the original
function in our hook if someone else is hooking it.
Thanks to @remicollet for the bug report and troubleshooting
Diffstat (limited to 'src/sp_execute.c')
| -rw-r--r-- | src/sp_execute.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/sp_execute.c b/src/sp_execute.c index bf9c907..20fe509 100644 --- a/src/sp_execute.c +++ b/src/sp_execute.c | |||
| @@ -131,10 +131,10 @@ static void sp_execute_ex(zend_execute_data *execute_data) { | |||
| 131 | static void sp_zend_execute_internal(INTERNAL_FUNCTION_PARAMETERS) { | 131 | static void sp_zend_execute_internal(INTERNAL_FUNCTION_PARAMETERS) { |
| 132 | is_in_eval_and_whitelisted(execute_data); | 132 | is_in_eval_and_whitelisted(execute_data); |
| 133 | 133 | ||
| 134 | EX(func)->internal_function.handler(INTERNAL_FUNCTION_PARAM_PASSTHRU); | ||
| 135 | |||
| 136 | if (UNEXPECTED(NULL != orig_zend_execute_internal)) { | 134 | if (UNEXPECTED(NULL != orig_zend_execute_internal)) { |
| 137 | orig_zend_execute_internal(INTERNAL_FUNCTION_PARAM_PASSTHRU); | 135 | orig_zend_execute_internal(INTERNAL_FUNCTION_PARAM_PASSTHRU); |
| 136 | } else { | ||
| 137 | EX(func)->internal_function.handler(INTERNAL_FUNCTION_PARAM_PASSTHRU); | ||
| 138 | } | 138 | } |
| 139 | } | 139 | } |
| 140 | 140 | ||
