Skip to content

Commit

Permalink
avert chmod on any symlink
Browse files Browse the repository at this point in the history
  • Loading branch information
andk committed Nov 3, 2024
1 parent da089bf commit 4a940cf
Showing 1 changed file with 4 additions and 1 deletion.
5 changes: 4 additions & 1 deletion bin/paused
Original file line number Diff line number Diff line change
Expand Up @@ -875,10 +875,13 @@ sub _rewrite_tarball {
open my $fh, "-|", tar => "-C", $testdir, $taropt, "-xvvf", $path or die "could not fork";
my(@ww); #world-writable
my(@dnx); #directories-not-xessable
while (<$fh>) {
TARX: while (<$fh>) {
chomp;
my($stat,@rest) = split " ", $_;
my($dir,$ur,$uw,$ux,$gr,$gw,$gx,$or,$ow,$ox) = $stat =~ /^(.)(.)(.)(.)(.)(.)(.)(.)(.)(.)/;
if ($dir && $dir eq "l") {
next TARX: # avert chmod on any symlink
}
if ($ow && $ow eq "w") {
push @ww, $rest[-1];
}
Expand Down

0 comments on commit 4a940cf

Please sign in to comment.