Code Duplication    Length = 5-6 lines in 3 locations

app/Vendor/PHPExcel/PHPExcel/Shared/PCLZip/pclzip.lib.php 3 locations

@@ 2814-2818 (lines=5) @@
2811
2812
    // ----- Creates a compressed temporary file
2813
    $v_gzip_temp_name = PCLZIP_TEMPORARY_DIR.uniqid('pclzip-').'.gz';
2814
    if (($v_file_compressed = @gzopen($v_gzip_temp_name, "wb")) == 0) {
2815
      fclose($v_file);
2816
      PclZip::privErrorLog(PCLZIP_ERR_WRITE_OPEN_FAIL, 'Unable to open temporary file \''.$v_gzip_temp_name.'\' in binary write mode');
2817
      return PclZip::errorCode();
2818
    }
2819
2820
    // ----- Read the file by PCLZIP_READ_BLOCK_SIZE octets blocks
2821
    $v_size = filesize($p_filename);
@@ 3972-3976 (lines=5) @@
3969
        
3970
    // ----- Creates a temporary file
3971
    $v_gzip_temp_name = PCLZIP_TEMPORARY_DIR.uniqid('pclzip-').'.gz';
3972
    if (($v_dest_file = @fopen($v_gzip_temp_name, "wb")) == 0) {
3973
      fclose($v_file);
3974
      PclZip::privErrorLog(PCLZIP_ERR_WRITE_OPEN_FAIL, 'Unable to open temporary file \''.$v_gzip_temp_name.'\' in binary write mode');
3975
      return PclZip::errorCode();
3976
    }
3977
3978
3979
    // ----- Write gz file format header
@@ 4008-4013 (lines=6) @@
4005
    }
4006
4007
    // ----- Open the temporary gz file
4008
    if (($v_src_file = @gzopen($v_gzip_temp_name, 'rb')) == 0) {
4009
      @fclose($v_dest_file);
4010
      $p_entry['status'] = "read_error";
4011
      PclZip::privErrorLog(PCLZIP_ERR_READ_OPEN_FAIL, 'Unable to open temporary file \''.$v_gzip_temp_name.'\' in binary read mode');
4012
      return PclZip::errorCode();
4013
    }
4014
4015
4016
    // ----- Read the file by PCLZIP_READ_BLOCK_SIZE octets blocks