1--TEST--
2strnat(case)cmp(): potential OOB access for unterminated strings
3--SKIPIF--
4<?php
5if (!function_exists('zend_create_unterminated_string')) die('skip zend_test extension not available');
6?>
7--FILE--
8<?php
9$a = zend_create_unterminated_string('333');
10$b = zend_create_unterminated_string('333 ');
11var_dump(
12    strnatcmp($a, $b),
13    strnatcasecmp($b, $a)
14);
15zend_terminate_string($a);
16zend_terminate_string($b);
17?>
18--EXPECT--
19int(-1)
20int(1)
21