@@ 2855-2858 (lines=4) @@ | ||
2852 | @gzclose($v_file_compressed); |
|
2853 | ||
2854 | // ----- Check the minimum file size |
|
2855 | if (filesize($v_gzip_temp_name) < 18) { |
|
2856 | PclZip::privErrorLog(PCLZIP_ERR_BAD_FORMAT, 'gzip temporary file \''.$v_gzip_temp_name.'\' has invalid filesize - should be minimum 18 bytes'); |
|
2857 | return PclZip::errorCode(); |
|
2858 | } |
|
2859 | ||
2860 | // ----- Extract the compressed attributes |
|
2861 | if (($v_file_compressed = @fopen($v_gzip_temp_name, "rb")) == 0) { |
|
@@ 4649-4657 (lines=9) @@ | ||
4646 | $v_binary_data = fread($this->zip_fd, 18); |
|
4647 | ||
4648 | // ----- Look for invalid block size |
|
4649 | if (strlen($v_binary_data) != 18) |
|
4650 | { |
|
4651 | ||
4652 | // ----- Error log |
|
4653 | PclZip::privErrorLog(PCLZIP_ERR_BAD_FORMAT, "Invalid End of Central Dir Record size : ".strlen($v_binary_data)); |
|
4654 | ||
4655 | // ----- Return |
|
4656 | return PclZip::errorCode(); |
|
4657 | } |
|
4658 | ||
4659 | // ----- Extract the values |
|
4660 | $v_data = unpack('vdisk/vdisk_start/vdisk_entries/ventries/Vsize/Voffset/vcomment_size', $v_binary_data); |