Skip to content

Update ext/phar parameter names #6307

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
wants to merge 2 commits into from
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
148 changes: 73 additions & 75 deletions ext/phar/phar_object.stub.php

Large diffs are not rendered by default.

85 changes: 45 additions & 40 deletions ext/phar/phar_object_arginfo.h
Original file line number Diff line number Diff line change
@@ -1,5 +1,5 @@
/* This is a generated file, edit the .stub.php file instead.
* Stub hash: 8dff2050ad65f94a41176cfb280d02c4fb61dcf7 */
* Stub hash: e06a2ea3d97778e61aca0f91fda7b72c29ef171d */

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar___construct, 0, 0, 1)
ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 0)
Expand All @@ -11,69 +11,69 @@ ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar___destruct, 0, 0, 0)
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_addEmptyDir, 0, 0, 1)
ZEND_ARG_TYPE_INFO(0, dirname, IS_STRING, 0)
ZEND_ARG_TYPE_INFO(0, directory, IS_STRING, 0)
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_addFile, 0, 0, 1)
ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, localname, IS_STRING, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, localName, IS_STRING, 1, "null")
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_addFromString, 0, 0, 2)
ZEND_ARG_TYPE_INFO(0, localname, IS_STRING, 0)
ZEND_ARG_TYPE_INFO(0, localName, IS_STRING, 0)
ZEND_ARG_TYPE_INFO(0, contents, IS_STRING, 0)
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_buildFromDirectory, 0, 0, 1)
ZEND_ARG_TYPE_INFO(0, base_dir, IS_STRING, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, regex, IS_STRING, 0, "\"\"")
ZEND_ARG_TYPE_INFO(0, directory, IS_STRING, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, pattern, IS_STRING, 0, "\"\"")
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_buildFromIterator, 0, 0, 1)
ZEND_ARG_OBJ_INFO(0, iterator, Traversable, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, base_directory, IS_STRING, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, baseDirectory, IS_STRING, 1, "null")
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_compressFiles, 0, 0, 1)
ZEND_ARG_TYPE_INFO(0, compression_type, IS_LONG, 0)
ZEND_ARG_TYPE_INFO(0, compression, IS_LONG, 0)
ZEND_END_ARG_INFO()

#define arginfo_class_Phar_decompressFiles arginfo_class_Phar___destruct

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_compress, 0, 0, 1)
ZEND_ARG_TYPE_INFO(0, compression_type, IS_LONG, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, file_ext, IS_STRING, 1, "null")
ZEND_ARG_TYPE_INFO(0, compression, IS_LONG, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, extension, IS_STRING, 1, "null")
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_decompress, 0, 0, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, file_ext, IS_STRING, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, extension, IS_STRING, 1, "null")
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_convertToExecutable, 0, 0, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, format, IS_LONG, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, compression_type, IS_LONG, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, file_ext, IS_STRING, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, compression, IS_LONG, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, extension, IS_STRING, 1, "null")
ZEND_END_ARG_INFO()

#define arginfo_class_Phar_convertToData arginfo_class_Phar_convertToExecutable

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_copy, 0, 0, 2)
ZEND_ARG_TYPE_INFO(0, newfile, IS_STRING, 0)
ZEND_ARG_TYPE_INFO(0, oldfile, IS_STRING, 0)
ZEND_ARG_TYPE_INFO(0, to, IS_STRING, 0)
ZEND_ARG_TYPE_INFO(0, from, IS_STRING, 0)
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_count, 0, 0, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, mode, IS_LONG, 0, "COUNT_NORMAL")
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_delete, 0, 0, 1)
ZEND_ARG_TYPE_INFO(0, entry, IS_STRING, 0)
ZEND_ARG_TYPE_INFO(0, localName, IS_STRING, 0)
ZEND_END_ARG_INFO()

#define arginfo_class_Phar_delMetadata arginfo_class_Phar___destruct

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_extractTo, 0, 0, 1)
ZEND_ARG_TYPE_INFO(0, pathto, IS_STRING, 0)
ZEND_ARG_TYPE_INFO(0, directory, IS_STRING, 0)
ZEND_ARG_TYPE_MASK(0, files, MAY_BE_ARRAY|MAY_BE_STRING|MAY_BE_NULL, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, overwrite, _IS_BOOL, 0, "false")
ZEND_END_ARG_INFO()
Expand All @@ -83,7 +83,7 @@ ZEND_END_ARG_INFO()
#define arginfo_class_Phar_getPath arginfo_class_Phar___destruct

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_getMetadata, 0, 0, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, unserialize_options, IS_ARRAY, 0, "[]")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, unserializeOptions, IS_ARRAY, 0, "[]")
ZEND_END_ARG_INFO()

#define arginfo_class_Phar_getModified arginfo_class_Phar___destruct
Expand All @@ -101,19 +101,19 @@ ZEND_END_ARG_INFO()
#define arginfo_class_Phar_isCompressed arginfo_class_Phar___destruct

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_isFileFormat, 0, 0, 1)
ZEND_ARG_TYPE_INFO(0, fileformat, IS_LONG, 0)
ZEND_ARG_TYPE_INFO(0, format, IS_LONG, 0)
ZEND_END_ARG_INFO()

#define arginfo_class_Phar_isWritable arginfo_class_Phar___destruct

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_offsetExists, 0, 0, 1)
ZEND_ARG_INFO(0, entry)
ZEND_ARG_INFO(0, localName)
ZEND_END_ARG_INFO()

#define arginfo_class_Phar_offsetGet arginfo_class_Phar_offsetExists

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_offsetSet, 0, 0, 2)
ZEND_ARG_INFO(0, entry)
ZEND_ARG_INFO(0, localName)
ZEND_ARG_INFO(0, value)
ZEND_END_ARG_INFO()

Expand All @@ -125,21 +125,21 @@ ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_setDefaultStub, 0, 0, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, index, IS_STRING, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, webindex, IS_STRING, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, webIndex, IS_STRING, 1, "null")
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_setMetadata, 0, 0, 1)
ZEND_ARG_TYPE_INFO(0, metadata, IS_MIXED, 0)
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_setSignatureAlgorithm, 0, 0, 1)
ZEND_ARG_TYPE_INFO(0, algorithm, IS_LONG, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, privatekey, IS_STRING, 1, "null")
ZEND_ARG_TYPE_INFO(0, algo, IS_LONG, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, privateKey, IS_STRING, 1, "null")
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_Phar_setStub, 0, 0, 1)
ZEND_ARG_INFO(0, newstub)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, maxlen, IS_LONG, 0, "-1")
ZEND_ARG_INFO(0, stub)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, length, IS_LONG, 0, "-1")
ZEND_END_ARG_INFO()

#define arginfo_class_Phar_startBuffering arginfo_class_Phar___destruct
Expand All @@ -150,15 +150,15 @@ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Phar_apiVersion, 0, 0, IS_
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Phar_canCompress, 0, 0, _IS_BOOL, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, method, IS_LONG, 0, "0")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, compression, IS_LONG, 0, "0")
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Phar_canWrite, 0, 0, _IS_BOOL, 0)
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Phar_createDefaultStub, 0, 0, IS_STRING, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, index, IS_STRING, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, webindex, IS_STRING, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, webIndex, IS_STRING, 1, "null")
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Phar_getSupportedCompression, 0, 0, IS_ARRAY, 0)
Expand All @@ -185,35 +185,35 @@ ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Phar_mapPhar, 0, 0, _IS_BO
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Phar_running, 0, 0, IS_STRING, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, retphar, _IS_BOOL, 0, "true")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, returnPhar, _IS_BOOL, 0, "true")
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Phar_mount, 0, 2, IS_VOID, 0)
ZEND_ARG_TYPE_INFO(0, inphar, IS_STRING, 0)
ZEND_ARG_TYPE_INFO(0, externalfile, IS_STRING, 0)
ZEND_ARG_TYPE_INFO(0, pharPath, IS_STRING, 0)
ZEND_ARG_TYPE_INFO(0, externalPath, IS_STRING, 0)
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Phar_mungServer, 0, 1, IS_VOID, 0)
ZEND_ARG_TYPE_INFO(0, munglist, IS_ARRAY, 0)
ZEND_ARG_TYPE_INFO(0, variables, IS_ARRAY, 0)
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Phar_unlinkArchive, 0, 1, _IS_BOOL, 0)
ZEND_ARG_TYPE_INFO(0, archive, IS_STRING, 0)
ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 0)
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_WITH_RETURN_TYPE_INFO_EX(arginfo_class_Phar_webPhar, 0, 0, IS_VOID, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, alias, IS_STRING, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, index, IS_STRING, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, f404, IS_STRING, 0, "\"\"")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, mimetypes, IS_ARRAY, 0, "[]")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, rewrites, IS_CALLABLE, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, fileNotFoundScript, IS_STRING, 0, "\"\"")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, mimeTypes, IS_ARRAY, 0, "[]")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, rewrite, IS_CALLABLE, 1, "null")
ZEND_END_ARG_INFO()

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_PharData___construct, 0, 0, 1)
ZEND_ARG_TYPE_INFO(0, filename, IS_STRING, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, flags, IS_LONG, 0, "FilesystemIterator::SKIP_DOTS | FilesystemIterator::UNIX_PATHS")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, alias, IS_STRING, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, fileformat, IS_LONG, 0, "0")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, format, IS_LONG, 0, "0")
ZEND_END_ARG_INFO()

#define arginfo_class_PharData___destruct arginfo_class_Phar___destruct
Expand Down Expand Up @@ -254,7 +254,9 @@ ZEND_END_ARG_INFO()

#define arginfo_class_PharData_getPath arginfo_class_Phar___destruct

#define arginfo_class_PharData_getMetadata arginfo_class_Phar_getMetadata
ZEND_BEGIN_ARG_INFO_EX(arginfo_class_PharData_getMetadata, 0, 0, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, unserialize_options, IS_ARRAY, 0, "[]")
ZEND_END_ARG_INFO()

#define arginfo_class_PharData_getModified arginfo_class_Phar___destruct

Expand Down Expand Up @@ -290,7 +292,10 @@ ZEND_END_ARG_INFO()

#define arginfo_class_PharData_setSignatureAlgorithm arginfo_class_Phar_setSignatureAlgorithm

#define arginfo_class_PharData_setStub arginfo_class_Phar_setStub
ZEND_BEGIN_ARG_INFO_EX(arginfo_class_PharData_setStub, 0, 0, 1)
ZEND_ARG_INFO(0, newstub)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, maxlen, IS_LONG, 0, "-1")
ZEND_END_ARG_INFO()

#define arginfo_class_PharData_startBuffering arginfo_class_Phar___destruct

Expand Down Expand Up @@ -355,7 +360,7 @@ ZEND_END_ARG_INFO()
#define arginfo_class_PharFileInfo_hasMetadata arginfo_class_Phar___destruct

ZEND_BEGIN_ARG_INFO_EX(arginfo_class_PharFileInfo_isCompressed, 0, 0, 0)
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, compression_type, IS_LONG, 1, "null")
ZEND_ARG_TYPE_INFO_WITH_DEFAULT_VALUE(0, compression, IS_LONG, 1, "null")
ZEND_END_ARG_INFO()

#define arginfo_class_PharFileInfo_isCRCChecked arginfo_class_Phar___destruct
Expand Down
20 changes: 10 additions & 10 deletions ext/phar/tests/badparameters.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -228,14 +228,14 @@ try {
}
?>
--EXPECTF--
Phar::mungServer(): Argument #1 ($munglist) must be of type array, string given
Phar::mungServer(): Argument #1 ($variables) must be of type array, string given
Phar::createDefaultStub(): Argument #1 ($index) must be of type ?string, array given
Phar::loadPhar(): Argument #1 ($filename) must be of type string, array given
Phar::canCompress(): Argument #1 ($method) must be of type int, string given
Phar::canCompress(): Argument #1 ($compression) must be of type int, string given
Phar::__construct(): Argument #1 ($filename) must be of type string, array given
Phar::convertToExecutable(): Argument #1 ($format) must be of type ?int, array given
Phar::convertToData(): Argument #1 ($format) must be of type ?int, array given
PharData::delete(): Argument #1 ($entry) must be of type string, array given
PharData::delete(): Argument #1 ($localName) must be of type string, array given
Cannot write out phar archive, phar is read-only
Entry oops does not exist and cannot be deleted
%sfrontcontroller10.phar
Expand All @@ -244,23 +244,23 @@ A Phar alias cannot be set in a plain tar archive
Phar::setAlias(): Argument #1 ($alias) must be of type string, array given
Cannot change stub, phar is read-only
A Phar stub cannot be set in a plain tar archive
Phar::setStub(): Argument #1 ($newstub) must be of type string, array given
Phar::setStub(): Argument #1 ($stub) must be of type string, array given
A Phar stub cannot be set in a plain tar archive
Phar::setDefaultStub(): Argument #1 ($index) must be of type ?string, array given
Cannot change stub: phar.readonly=1
Cannot set signature algorithm, phar is read-only
Phar::compress(): Argument #1 ($compression_type) must be of type int, array given
Phar::compress(): Argument #1 ($compression) must be of type int, array given
Cannot compress phar archive, phar is read-only
Phar::compressFiles(): Argument #1 ($compression_type) must be of type int, array given
Phar::compressFiles(): Argument #1 ($compression) must be of type int, array given
Phar is readonly, cannot change compression
Phar::copy() expects exactly 2 arguments, 1 given
Cannot copy "a" to "b", phar is read-only
Phar::offsetExists(): Argument #1 ($entry) must be of type string, array given
Phar::offsetGet(): Argument #1 ($entry) must be of type string, array given
Phar::offsetExists(): Argument #1 ($localName) must be of type string, array given
Phar::offsetGet(): Argument #1 ($localName) must be of type string, array given
Phar::offsetSet() expects exactly 2 arguments, 1 given
PharData::offsetUnset(): Argument #1 ($entry) must be of type string, array given
PharData::offsetUnset(): Argument #1 ($localName) must be of type string, array given
Write operations disabled by the php.ini setting phar.readonly
Phar::addEmptyDir(): Argument #1 ($dirname) must be of type string, array given
Phar::addEmptyDir(): Argument #1 ($directory) must be of type string, array given
Phar::addFile(): Argument #1 ($filename) must be of type string, array given
Phar::addFromString() expects exactly 2 arguments, 1 given
Write operations disabled by the php.ini setting phar.readonly
Expand Down
2 changes: 1 addition & 1 deletion ext/phar/tests/bug64931/bug64931.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -53,4 +53,4 @@ CAUGHT: Cannot create any files in magic ".phar" directory
CAUGHT: Cannot create any files in magic ".phar" directory
CAUGHT: Cannot create any files in magic ".phar" directory
CAUGHT: Cannot create any files in magic ".phar" directory
CAUGHT: Phar::addFromString(): Argument #1 ($localname) must not contain any null bytes
CAUGHT: Phar::addFromString(): Argument #1 ($localName) must not contain any null bytes
2 changes: 1 addition & 1 deletion ext/phar/tests/cache_list/frontcontroller31.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,7 @@ Content-type: text/html; charset=UTF-8
--FILE_EXTERNAL--
files/frontcontroller16.phar
--EXPECTF--
Fatal error: Uncaught TypeError: Phar::webPhar(): Argument #5 ($rewrites) must be a valid callback or null, class "fail" not found in %s:%d
Fatal error: Uncaught TypeError: Phar::webPhar(): Argument #5 ($rewrite) must be a valid callback or null, class "fail" not found in %s:%d
Stack trace:
#0 %s(%d): Phar::webPhar('test.phar', '/index.php', '', Array, Array)
#1 {main}
Expand Down
2 changes: 1 addition & 1 deletion ext/phar/tests/create_path_error.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -78,4 +78,4 @@ string(5) "query"
11:Error: file_put_contents(phar://%s): Failed to open stream: phar error: invalid path "%s" contains illegal character
12:Error: file_put_contents(phar://%s): Failed to open stream: phar error: invalid path "%s" contains illegal character
13:Error: file_put_contents(phar://%s): Failed to open stream: phar error: invalid path "%s" contains illegal character
Exception: Phar::offsetSet(): Argument #1 ($entry) must not contain any null bytes
Exception: Phar::offsetSet(): Argument #1 ($localName) must not contain any null bytes
2 changes: 1 addition & 1 deletion ext/phar/tests/frontcontroller31.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@ Content-type: text/html; charset=UTF-8
--FILE_EXTERNAL--
files/frontcontroller16.phar
--EXPECTF--
Fatal error: Uncaught TypeError: Phar::webPhar(): Argument #5 ($rewrites) must be a valid callback or null, class "fail" not found in %s:%d
Fatal error: Uncaught TypeError: Phar::webPhar(): Argument #5 ($rewrite) must be a valid callback or null, class "fail" not found in %s:%d
Stack trace:
#0 %s(%d): Phar::webPhar('test.phar', '/index.php', '', Array, Array)
#1 {main}
Expand Down
2 changes: 1 addition & 1 deletion ext/phar/tests/phar_extract.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -142,7 +142,7 @@ string(3) "hi3"
string(3) "hi2"
bool(false)
Phar::extractTo(): Argument #2 ($files) must be of type array|string|null, stdClass given
Phar::extractTo(): Argument #1 ($pathto) must be of type string, array given
Phar::extractTo(): Argument #1 ($directory) must be of type string, array given
Invalid argument, extraction path must be non-zero length
Unable to use path "%soops" for extraction, it is a file, must be a directory
Invalid argument, array of filenames to extract contains non-string value
Expand Down
2 changes: 1 addition & 1 deletion ext/phar/tests/phar_unlinkarchive.phpt
Original file line number Diff line number Diff line change
Expand Up @@ -92,7 +92,7 @@ __HALT_COMPILER();
Unknown phar archive ""
Unknown phar archive "%sphar_unlinkarchive.phar"
Unknown phar archive "%sphar_unlinkarchive.phar.tar": internal corruption of phar "%sphar_unlinkarchive.phar.tar" (truncated entry)
Phar::unlinkArchive(): Argument #1 ($archive) must be of type string, array given
Phar::unlinkArchive(): Argument #1 ($filename) must be of type string, array given
bool(false)
string(48) "<?php echo "first stub\n"; __HALT_COMPILER(); ?>"
phar archive "%sphar_unlinkarchive.phar" has open file handles or objects. fclose() all file handles, and unset() all objects prior to calling unlinkArchive()
Expand Down