optimize for common case where list is not changed

master
Joey Hess 2013-07-10 17:40:33 -04:00
parent d932d5ab00
commit 46e0c5742c
1 changed files with 1 additions and 1 deletions

View File

@ -773,7 +773,7 @@ sub refresh () {
my %existingfiles;
run_hooks(needsbuild => sub {
my $ret=shift->($changed, [@$del, @$internal_del]);
if (ref $ret eq 'ARRAY') {
if (ref $ret eq 'ARRAY' && $ret != $changed) {
if (! %existingfiles) {
foreach my $f (@$files) {
$existingfiles{$f}=1;