summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--IkiWiki/Plugin/attachment.pm3
-rw-r--r--IkiWiki/Render.pm2
2 files changed, 4 insertions, 1 deletions
diff --git a/IkiWiki/Plugin/attachment.pm b/IkiWiki/Plugin/attachment.pm
index 106660012..a474f6e75 100644
--- a/IkiWiki/Plugin/attachment.pm
+++ b/IkiWiki/Plugin/attachment.pm
@@ -72,6 +72,9 @@ sub formbuilder (@) { #{{{
}
}
+ # Needed for fast_file_copy.
+ require IkiWiki::Render;
+
# Move the attachment into place.
# Try to use a fast rename; fall back to copying.
IkiWiki::prep_writefile($filename, $config{srcdir});
diff --git a/IkiWiki/Render.pm b/IkiWiki/Render.pm
index 2cdec421f..5184be2df 100644
--- a/IkiWiki/Render.pm
+++ b/IkiWiki/Render.pm
@@ -180,7 +180,7 @@ sub scan ($) { #{{{
}
} #}}}
-sub fast_file_copy ($$$$$) { #{{{
+sub fast_file_copy (@) { #{{{
my $srcfile=shift;
my $destfile=shift;
my $srcfd=shift;