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