Code Duplication    Length = 4-9 lines in 3 locations

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

@@ 3827-3835 (lines=9) @@
3824
        if ($p_entry['compression'] == 0) {
3825
3826
    		  // ----- Opening destination file
3827
          if (($v_dest_file = @fopen($p_entry['filename'], 'wb')) == 0)
3828
          {
3829
3830
            // ----- Change the file status
3831
            $p_entry['status'] = "write_error";
3832
3833
            // ----- Return
3834
            return $v_result;
3835
          }
3836
3837
3838
          // ----- Read the file by PCLZIP_READ_BLOCK_SIZE octets blocks
@@ 3900-3906 (lines=7) @@
3897
            }
3898
            
3899
            // ----- Opening destination file
3900
            if (($v_dest_file = @fopen($p_entry['filename'], 'wb')) == 0) {
3901
  
3902
              // ----- Change the file status
3903
              $p_entry['status'] = "write_error";
3904
  
3905
              return $v_result;
3906
            }
3907
  
3908
            // ----- Write the uncompressed data
3909
            @fwrite($v_dest_file, $v_file_content, $p_entry['size']);
@@ 4002-4005 (lines=4) @@
3999
    @fclose($v_dest_file);
4000
4001
    // ----- Opening destination file
4002
    if (($v_dest_file = @fopen($p_entry['filename'], 'wb')) == 0) {
4003
      $p_entry['status'] = "write_error";
4004
      return $v_result;
4005
    }
4006
4007
    // ----- Open the temporary gz file
4008
    if (($v_src_file = @gzopen($v_gzip_temp_name, 'rb')) == 0) {