]> git.donarmstrong.com Git - debbugs.git/commitdiff
[project @ 2004-03-17 17:18:41 by cjwatson]
authorcjwatson <>
Thu, 18 Mar 2004 01:18:41 +0000 (17:18 -0800)
committercjwatson <>
Thu, 18 Mar 2004 01:18:41 +0000 (17:18 -0800)
Sanitize # to %23 in attachment URLs (but not where it's supposed to
introduce an anchor, obviously).

cgi/common.pl

index 419930c82f2bd96c7f258b2fbbed46c5e12a1694..082eb2d978161ddc417f3cf6761f0652535be4d5 100644 (file)
@@ -407,6 +407,7 @@ sub tagurl {
 sub urlsanit {
     my $url = shift;
     $url =~ s/%/%25/g;
+    $url =~ s/#/%23/g;
     $url =~ s/\+/%2b/g;
     my %saniarray = ('<','lt', '>','gt', '&','amp', '"','quot');
     $url =~ s/([<>&"])/\&$saniarray{$1};/g;