Skip to content

Commit 56fc4c7

Browse files
rapperskullthrimbor
authored andcommitted
Treat an empty root as any other empty directory
1 parent fdcb529 commit 56fc4c7

File tree

1 file changed

+1
-3
lines changed

1 file changed

+1
-3
lines changed

extract-xiso.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -999,8 +999,6 @@ int create_xiso( char *in_root_directory, char *in_output_directory, dir_node_av
999999

10001000
s_total_bytes = s_total_files = 0;
10011001

1002-
if ( root.subdirectory == EMPTY_SUBDIRECTORY ) root.start_sector = root.file_size = 0;
1003-
10041002
start_sector = root.start_sector;
10051003

10061004
avl_traverse_depth_first( &root, (traversal_callback) calculate_directory_requirements, nil, k_prefix, 0 );
@@ -1047,7 +1045,7 @@ int create_xiso( char *in_root_directory, char *in_output_directory, dir_node_av
10471045
}
10481046
if ( ! err && ( root.filename = strdup( iso_dir ) ) == nil ) mem_err();
10491047

1050-
if ( ! err && root.start_sector && lseek( xiso, (xoff_t) root.start_sector * XISO_SECTOR_SIZE, SEEK_SET ) == -1 ) seek_err();
1048+
if ( ! err && lseek( xiso, (xoff_t) root.start_sector * XISO_SECTOR_SIZE, SEEK_SET ) == -1 ) seek_err();
10511049
if ( ! err ) {
10521050
wt_context.path = nil;
10531051
wt_context.xiso = xiso;

0 commit comments

Comments
 (0)