summaryrefslogtreecommitdiffstats
path: root/urpm/parallel_ssh.pm
diff options
context:
space:
mode:
Diffstat (limited to 'urpm/parallel_ssh.pm')
-rw-r--r--urpm/parallel_ssh.pm5
1 files changed, 3 insertions, 2 deletions
diff --git a/urpm/parallel_ssh.pm b/urpm/parallel_ssh.pm
index 4b11e8c7..02f59f06 100644
--- a/urpm/parallel_ssh.pm
+++ b/urpm/parallel_ssh.pm
@@ -25,8 +25,9 @@ sub scp_rpms {
foreach my $host (keys %{$parallel->{nodes}}) {
$urpm->{log}("parallel_ssh: scp @files $host:$urpm->{cachedir}/rpms");
if (_localhost($host)) {
- my @f = grep { ! m!^$urpm->{cachedir}/rpms! } @files;
- @f and system('cp', @f, "$urpm->{cachedir}/rpms");
+ if (my @f = grep { dirname($_) ne "$urpm->{cachedir}/rpms" } @files) {
+ system('cp', @f, "$urpm->{cachedir}/rpms");
+ }
} else {
system('scp', @files, "$host:$urpm->{cachedir}/rpms");
}