xref: /PHP-8.2/ext/phar/tests/bug66960.phpt (revision 98d004c9)
1--TEST--
2Bug #66960 phar long filename crash
3--EXTENSIONS--
4phar
5--INI--
6phar.readonly = 0
7memory_limit = -1
8--FILE--
9<?php
10$file = __DIR__ . DIRECTORY_SEPARATOR . 'bug66960.phar';
11$phar = new Phar($file);
12var_dump(file_exists("phar://$file/". str_repeat('a', PHP_MAXPATHLEN-1)));
13var_dump(file_exists("phar://$file/". str_repeat('a', PHP_MAXPATHLEN)));
14var_dump(file_exists("phar://$file/". str_repeat('a', PHP_MAXPATHLEN+1)));
15echo 'done';
16?>
17--EXPECT--
18bool(false)
19bool(false)
20bool(false)
21done
22