]> sipb.mit.edu Git - ikiwiki.git/commitdiff
fix expensive move code path
authorJoey Hess <joey@kodama.kitenet.net>
Tue, 1 Jul 2008 17:48:07 +0000 (13:48 -0400)
committerJoey Hess <joey@kodama.kitenet.net>
Tue, 1 Jul 2008 17:48:07 +0000 (13:48 -0400)
IkiWiki/Plugin/attachment.pm
IkiWiki/Render.pm

index 106660012cb31029a62cc8b703b8558655e57440..a474f6e75f58b178b2b049fd1c4e590740a4d6f2 100644 (file)
@@ -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});
index 2cdec421f1da745e6f6aa2060be1ce46b566a822..5184be2df0129bf9837aaabd91133dd1b1e3ba96 100644 (file)
@@ -180,7 +180,7 @@ sub scan ($) { #{{{
        }
 } #}}}
 
-sub fast_file_copy ($$$$$) { #{{{
+sub fast_file_copy (@) { #{{{
        my $srcfile=shift;
        my $destfile=shift;
        my $srcfd=shift;