aboutsummaryrefslogtreecommitdiffstats
path: root/packdrake.pm
diff options
context:
space:
mode:
authorFrancois Pons <fpons@mandriva.com>2001-01-05 15:24:13 +0000
committerFrancois Pons <fpons@mandriva.com>2001-01-05 15:24:13 +0000
commitd0129d910203a3516ccacf767a8f23b33bd73fc5 (patch)
tree0c60a4f4aaf0b25c3d8c768dce883de3b113b819 /packdrake.pm
parentf2cd5f432f6a2474fbd44a1c0fb9feb9cf99ad8d (diff)
downloadrpmtools-d0129d910203a3516ccacf767a8f23b33bd73fc5.tar
rpmtools-d0129d910203a3516ccacf767a8f23b33bd73fc5.tar.gz
rpmtools-d0129d910203a3516ccacf767a8f23b33bd73fc5.tar.bz2
rpmtools-d0129d910203a3516ccacf767a8f23b33bd73fc5.tar.xz
rpmtools-d0129d910203a3516ccacf767a8f23b33bd73fc5.zip
really fixe exit in child process (when used with DrakX, exit is not allowed)
Diffstat (limited to 'packdrake.pm')
-rw-r--r--packdrake.pm6
1 files changed, 3 insertions, 3 deletions
diff --git a/packdrake.pm b/packdrake.pm
index 2902d37..97d004f 100644
--- a/packdrake.pm
+++ b/packdrake.pm
@@ -382,7 +382,7 @@ sub extract_archive {
#- of uncompress executable.
foreach (sort { $a <=> $b } keys %extract_table) {
local *OUTPUT;
- if (my $pid = open OUTPUT, "-|") {
+ if (open OUTPUT, "-|") {
#- $curr_off is used to handle the reading in a pipe and simulating
#- a seek on it as done by catsksz, so last file position is
#- last byte not read (ie last block read start + last block read size).
@@ -394,14 +394,14 @@ sub extract_archive {
catsksz(\*OUTPUT, $off - $curr_off, $siz, \*FILE);
$curr_off = $off + $siz;
}
- waitpid $pid, 0;
+ close FILE;
} else {
local *BUNZIP2;
open BUNZIP2, "| $packer->{uncompress}";
local *ARCHIVE;
open ARCHIVE, "<$packer->{archive}" or die "packdrake: cannot open archive $packer->{archive}\n";
catsksz(\*ARCHIVE, $_, $extract_table{$_}[0], \*BUNZIP2);
- exec 'true';
+ exec 'true'; #- exit ala _exit
}
}
}