Code Duplication    Length = 17-17 lines in 2 locations

class/pcltar.lib.php 2 locations

@@ 2243-2259 (lines=17) @@
2240
            }
2241
2242
            // ----- File name and properties are logged if listing mode or file is extracted
2243
            if ($v_listing || $v_extract_file || $v_extraction_stopped) {
2244
                TrFctMessage(__FILE__, __LINE__, 2, 'Memorize info about file ' . $v_header['filename'] . '');
2245
2246
                // ----- Log extracted files
2247
                if (($v_file_dir = dirname($v_header['filename'])) == $v_header['filename']) {
2248
                    $v_file_dir = '';
2249
                }
2250
                if (('' === $v_file_dir) && (0 === strpos($v_header['filename'], '/'))) {
2251
                    $v_file_dir = '/';
2252
                }
2253
2254
                // ----- Add the array describing the file into the list
2255
                $p_list_detail[$v_nb] = $v_header;
2256
2257
                // ----- Increment
2258
                ++$v_nb;
2259
            }
2260
        }
2261
2262
        // ----- Close the tarfile
@@ 2507-2523 (lines=17) @@
2504
            }
2505
2506
            // ----- File name and properties are logged if listing mode or file is extracted
2507
            if ($v_extract_file) {
2508
                TrFctMessage(__FILE__, __LINE__, 2, 'Memorize info about file ' . $v_header['filename'] . '');
2509
2510
                // ----- Log extracted files
2511
                if (($v_file_dir = dirname($v_header['filename'])) == $v_header['filename']) {
2512
                    $v_file_dir = '';
2513
                }
2514
                if (('' === $v_file_dir) && (0 === strpos($v_header['filename'], '/'))) {
2515
                    $v_file_dir = '/';
2516
                }
2517
2518
                // ----- Add the array describing the file into the list
2519
                $p_list_detail[$v_nb] = $v_header;
2520
2521
                // ----- Increment
2522
                ++$v_nb;
2523
            }
2524
2525
            // ----- Increment the current file index
2526
            ++$p_index_current;