mirror of
https://github.com/Project-OSS-Revival/alien.git
synced 2026-04-24 14:00:17 +00:00
* Corrected precidence problem that made alien not catch mkdir of the work
directory failing if the directory already existed (and let it delete the
existing directory). Closes: #181061
* Fixed several other instances of the same precidence problem in the code.
This commit is contained in:
@@ -260,7 +260,7 @@ sub unpack {
|
||||
my $this=shift;
|
||||
|
||||
my $workdir = $this->name."-".$this->version;
|
||||
mkdir $workdir, 0755 ||
|
||||
mkdir($workdir, 0755) ||
|
||||
die "unable to mkdir $workdir: $!";
|
||||
# If the parent directory is suid/sgid, mkdir will make the root
|
||||
# directory of the package inherit those bits. That is a bad thing,
|
||||
@@ -327,7 +327,7 @@ sub DESTROY {
|
||||
if ($this->unpacked_tree eq '/') {
|
||||
die "alien internal error: unpacked_tree is set to `/'. Please file a bug report!";
|
||||
}
|
||||
system('rm', '-rf', $this->unpacked_tree) == 0
|
||||
(system('rm', '-rf', $this->unpacked_tree) == 0)
|
||||
or die "unable to delete temporary directory `".$this->unpacked_tree."`: $!";
|
||||
$this->unpacked_tree('');
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user