diff options
author | Anatol Belski <ab@php.net> | 2018-09-08 21:39:54 +0200 |
---|---|---|
committer | Anatol Belski <ab@php.net> | 2018-09-08 21:39:54 +0200 |
commit | 4905d5e0dfe13fa2645c34352d253b9a1ca11eed (patch) | |
tree | 3846f17efb1f50aca1ccd75fc181fc7787a00a05 | |
parent | c6ddd45650c295bdf800c600e89a15c0af9a1e09 (diff) | |
download | php-git-4905d5e0dfe13fa2645c34352d253b9a1ca11eed.tar.gz |
Add test for bug #76850
-rw-r--r-- | ext/pcre/tests/bug76850.phpt | 21 |
1 files changed, 21 insertions, 0 deletions
diff --git a/ext/pcre/tests/bug76850.phpt b/ext/pcre/tests/bug76850.phpt new file mode 100644 index 0000000000..ec06ccf897 --- /dev/null +++ b/ext/pcre/tests/bug76850.phpt @@ -0,0 +1,21 @@ +--TEST-- +Bug #76850 Exit code mangled by set locale/preg_match +--FILE-- +<?php + +function foo() +{ + $oldlocale = setlocale(LC_CTYPE, 0); + setlocale(LC_CTYPE, $oldlocale); +} + +foo(); + +var_dump(preg_match('/./', "a")); + +?> +==DONE== +--EXPECT-- +int(1) +==DONE== + |