diff options
Diffstat (limited to 'log.c')
| -rw-r--r-- | log.c | 6 |
1 files changed, 6 insertions, 0 deletions
| @@ -317,7 +317,9 @@ log_phpscript: | |||
| 317 | zval *result = NULL; | 317 | zval *result = NULL; |
| 318 | 318 | ||
| 319 | long orig_execution_depth = SUHOSIN_G(execution_depth); | 319 | long orig_execution_depth = SUHOSIN_G(execution_depth); |
| 320 | #if PHP_VERSION_ID < 50400 | ||
| 320 | zend_bool orig_safe_mode = PG(safe_mode); | 321 | zend_bool orig_safe_mode = PG(safe_mode); |
| 322 | #endif | ||
| 321 | char *orig_basedir = PG(open_basedir); | 323 | char *orig_basedir = PG(open_basedir); |
| 322 | 324 | ||
| 323 | char *phpscript = SUHOSIN_G(log_phpscriptname); | 325 | char *phpscript = SUHOSIN_G(log_phpscriptname); |
| @@ -354,14 +356,18 @@ SDEBUG("scriptname %s", SUHOSIN_G(log_phpscriptname)); | |||
| 354 | 356 | ||
| 355 | SUHOSIN_G(execution_depth) = 0; | 357 | SUHOSIN_G(execution_depth) = 0; |
| 356 | if (SUHOSIN_G(log_phpscript_is_safe)) { | 358 | if (SUHOSIN_G(log_phpscript_is_safe)) { |
| 359 | #if PHP_VERSION_ID < 50400 | ||
| 357 | PG(safe_mode) = 0; | 360 | PG(safe_mode) = 0; |
| 361 | #endif | ||
| 358 | PG(open_basedir) = NULL; | 362 | PG(open_basedir) = NULL; |
| 359 | } | 363 | } |
| 360 | 364 | ||
| 361 | zend_execute(new_op_array TSRMLS_CC); | 365 | zend_execute(new_op_array TSRMLS_CC); |
| 362 | 366 | ||
| 363 | SUHOSIN_G(execution_depth) = orig_execution_depth; | 367 | SUHOSIN_G(execution_depth) = orig_execution_depth; |
| 368 | #if PHP_VERSION_ID < 50400 | ||
| 364 | PG(safe_mode) = orig_safe_mode; | 369 | PG(safe_mode) = orig_safe_mode; |
| 370 | #endif | ||
| 365 | PG(open_basedir) = orig_basedir; | 371 | PG(open_basedir) = orig_basedir; |
| 366 | 372 | ||
| 367 | #ifdef ZEND_ENGINE_2 | 373 | #ifdef ZEND_ENGINE_2 |
