diff options
Diffstat (limited to 'src/sp_execute.c')
| -rw-r--r-- | src/sp_execute.c | 8 |
1 files changed, 6 insertions, 2 deletions
diff --git a/src/sp_execute.c b/src/sp_execute.c index b4e5c6c..5c0c939 100644 --- a/src/sp_execute.c +++ b/src/sp_execute.c | |||
| @@ -353,14 +353,18 @@ ZEND_API zend_op_array* sp_compile_string(zval* source_string, char* filename) { | |||
| 353 | // TODO(jvoisin) handle recursive calls to `eval` | 353 | // TODO(jvoisin) handle recursive calls to `eval` |
| 354 | SPG(eval_source_string) = source_string; | 354 | SPG(eval_source_string) = source_string; |
| 355 | zend_op_array* opline = orig_zend_compile_string(source_string, filename); | 355 | zend_op_array* opline = orig_zend_compile_string(source_string, filename); |
| 356 | sp_sloppy_modify_opcode(opline); | 356 | if (SPCFG(sloppy).enable) { |
| 357 | sp_sloppy_modify_opcode(opline); | ||
| 358 | } | ||
| 357 | return opline; | 359 | return opline; |
| 358 | } | 360 | } |
| 359 | 361 | ||
| 360 | ZEND_API zend_op_array* sp_compile_file(zend_file_handle* file_handle, | 362 | ZEND_API zend_op_array* sp_compile_file(zend_file_handle* file_handle, |
| 361 | int type) { | 363 | int type) { |
| 362 | zend_op_array* opline = orig_zend_compile_file(file_handle, type); | 364 | zend_op_array* opline = orig_zend_compile_file(file_handle, type); |
| 363 | sp_sloppy_modify_opcode(opline); | 365 | if (SPCFG(sloppy).enable) { |
| 366 | sp_sloppy_modify_opcode(opline); | ||
| 367 | } | ||
| 364 | return opline; | 368 | return opline; |
| 365 | } | 369 | } |
| 366 | 370 | ||
