output empty regions, since we might need them for padding

This commit is contained in:
Trammell hudson 2018-01-26 22:04:53 -05:00
parent 315bb0ac95
commit c1b15f69dc
Failed to extract signature

View File

@ -83,7 +83,7 @@ sub process_region
printf "%s/0x%08x.bin: UNKNOWN length 0x%x \n",
$base, $start_unknown, $len;
output(sprintf("%s/0x%08x.bin", $base, $start_unknown), $data);
output(sprintf("%s/0x%08x.bin", $base, $start_unknown), $data, 1);
undef $start_unknown;
}
@ -353,9 +353,10 @@ sub output
{
my $name = shift,
my $data = shift;
my $force = shift;
# check for an empty region (all the same value)
return if empty_data($data);
return if not $force and empty_data($data);
my $dir = dirname($name);
system(mkdir => -p => $dir)