Commit ffd48a5c authored by Mike Hibler's avatar Mike Hibler

Add a couple of missing FD closes.

This was causing eventual unmount of the customized FS to fail and
apparently causing the changes to get lost and/or cause FS problems.
parent ea2e26e7
......@@ -712,6 +712,7 @@ sub check_kernel
$buffer = substr $buffer, 1;
}
if ($rc == 0) {
close KERNEL;
return undef;
}
......@@ -723,7 +724,6 @@ sub check_kernel
close KERNEL;
close GZIP;
open KERNEL, $kernel_file or die "Couldn't open raw kernel: $!\n";
while (<KERNEL>) {
if (/ide[-_]disk/) {
......@@ -789,6 +789,7 @@ sub check_initrd
# be appended to the initial small one. I'm just not that in to it.
#
if (!$handles_label && !$handles_uuid && -f "$initrd_dir/early_cpio") {
print "Found initrd early_cpio; assuming handles label/UUID\n";
$handles_label = $handles_uuid = 1;
}
......@@ -802,12 +803,12 @@ sub check_initrd
split /:/;
push @loopdevs, $_[0];
}
close LOSETUP;
for my $dev (@loopdevs) {
`$LOSETUP -d $dev`;
}
return ($handles_label, $handles_uuid);
}
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment