mirror of
https://github.com/php/php-src.git
synced 2025-08-16 05:58:45 +02:00
23 lines
509 B
PHP
23 lines
509 B
PHP
--TEST--
|
|
ZipArchive::getExternalAttributesName() throws a ValueError when the $name param is empty
|
|
--EXTENSIONS--
|
|
zip
|
|
--FILE--
|
|
<?php
|
|
|
|
$zip = new ZipArchive();
|
|
$dirname = __DIR__ . '/';
|
|
|
|
$zip->open($dirname . "test.zip", ZIPARCHIVE::CREATE);
|
|
|
|
$a = ZipArchive::OPSYS_DEFAULT;
|
|
$b = ZipArchive::OPSYS_DEFAULT;
|
|
|
|
try {
|
|
$zip->getExternalAttributesName("", $a, $b);
|
|
} catch(ValueError $e) {
|
|
echo $e->getMessage();
|
|
}
|
|
?>
|
|
--EXPECT--
|
|
ZipArchive::getExternalAttributesName(): Argument #1 ($name) must not be empty
|