summaryrefslogtreecommitdiff
path: root/ext/zip/tests/bug53885.phpt
blob: 6f95a661b323bad98a51615936b9cde28cc710f0 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
--TEST--
Bug #53885 (ZipArchive segfault with FL_UNCHANGED on empty archive)
--SKIPIF--
<?php
if(!extension_loaded('zip')) die('skip');
?>
--FILE--
<?php
$fname = __DIR__."/test53885.zip";
if(file_exists($fname)) unlink($fname);
touch($fname);
$nx=new ZipArchive();
$nx->open($fname);
$nx->locateName("a",ZIPARCHIVE::FL_UNCHANGED);
$nx->statName("a",ZIPARCHIVE::FL_UNCHANGED);
?>
==DONE==
--CLEAN--
<?php
$fname = __DIR__."/test53885.zip";
unlink($fname);
?>
--EXPECT--
==DONE==