diff options
author | Remi Collet <remi@php.net> | 2020-02-28 10:21:19 +0100 |
---|---|---|
committer | Remi Collet <remi@php.net> | 2020-02-28 10:29:50 +0100 |
commit | d31fc591e0a852c69b81b3311b3609221f66c445 (patch) | |
tree | fcf19375a939b7839ce0fb943ea2263674b8bfc8 /ext/zip/php_zip.c | |
parent | 5b51b633e2509852312328d360639dacb35d12e6 (diff) | |
download | php-git-d31fc591e0a852c69b81b3311b3609221f66c445.tar.gz |
Fix #79315 ZipArchive::addFile doesn't honor start/length parameters
Diffstat (limited to 'ext/zip/php_zip.c')
-rw-r--r-- | ext/zip/php_zip.c | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/ext/zip/php_zip.c b/ext/zip/php_zip.c index e607f0f077..f65f70621e 100644 --- a/ext/zip/php_zip.c +++ b/ext/zip/php_zip.c @@ -1824,7 +1824,8 @@ static ZIPARCHIVE_METHOD(addFile) entry_name_len = ZSTR_LEN(filename); } - if (php_zip_add_file(intern, ZSTR_VAL(filename), ZSTR_LEN(filename), entry_name, entry_name_len, 0, 0) < 0) { + if (php_zip_add_file(intern, ZSTR_VAL(filename), ZSTR_LEN(filename), + entry_name, entry_name_len, offset_start, offset_len) < 0) { RETURN_FALSE; } else { RETURN_TRUE; |