diff options
Diffstat (limited to 'ext/opcache/tests/issue0057.phpt')
| -rw-r--r-- | ext/opcache/tests/issue0057.phpt | 38 |
1 files changed, 38 insertions, 0 deletions
diff --git a/ext/opcache/tests/issue0057.phpt b/ext/opcache/tests/issue0057.phpt new file mode 100644 index 0000000000..49e9156f15 --- /dev/null +++ b/ext/opcache/tests/issue0057.phpt @@ -0,0 +1,38 @@ +--TEST-- +ISSUE #57 (segfaults in drupal7) +--INI-- +opcache.enable=1 +opcache.enable_cli=1 +opcache.optimization_level=-1 +--SKIPIF-- +<?php require_once('skipif.inc'); ?> +--FILE-- +<?php + +class ZException extends Exception { +} + +function dummy($query) { + try { + switch ($query) { + case 1; + break; + case 2; + break; + default: + throw new Exception('exception'); + } + } catch (ZException $e) { + return NULL; + } +} + +try { + dummy(0); +} catch (Exception $e) { + echo $e->getMessage(); +} + +?> +--EXPECT-- +exception |
