]> sipb.mit.edu Git - ikiwiki.git/commitdiff
Fix escaping of filenames in historyurl. (Thanks, aj)
authorJoey Hess <joey@kitenet.net>
Tue, 16 Nov 2010 19:12:52 +0000 (15:12 -0400)
committerJoey Hess <joey@kitenet.net>
Tue, 16 Nov 2010 19:12:52 +0000 (15:12 -0400)
IkiWiki/Render.pm
debian/changelog

index 7ea919abc3d76c2b9fc280c81ed4f87cbb95d8cb..8e8336b994070f442061e8bc2929525a77033549 100644 (file)
@@ -5,7 +5,6 @@ package IkiWiki;
 use warnings;
 use strict;
 use IkiWiki;
-use Encode;
 
 my (%backlinks, %rendered);
 our %brokenlinks;
@@ -94,7 +93,8 @@ sub genpage ($$) {
        }
        if (defined $config{historyurl} && length $config{historyurl}) {
                my $u=$config{historyurl};
-               $u=~s/\[\[file\]\]/$pagesources{$page}/g;
+               my $p=uri_escape_utf8($pagesources{$page});
+               $u=~s/\[\[file\]\]/$p/g;
                $template->param(historyurl => $u);
                $actions++;
        }
index faabf1993194b7651519ab56f2b6c7253e0b2170..00c32e95d109857f6604fe1185319e6a4cb93409 100644 (file)
@@ -3,6 +3,7 @@ ikiwiki (3.20101113) UNRELEASED; urgency=low
   * websetup: Fix encoding problem when restoring old setup file.
   * more: Add pages parameter to limit where the more is displayed.
     (thanks, dark)
+  * Fix escaping of filenames in historyurl. (Thanks, aj)
 
  -- Joey Hess <joeyh@debian.org>  Tue, 16 Nov 2010 14:23:47 -0400