From ce312affa1487b2b3857da7de5cca35d35f3baa7 Mon Sep 17 00:00:00 2001 From: Jakub Narebski Date: Tue, 28 Aug 2007 16:05:43 +0200 Subject: [PATCH] gitweb: Fix escaping HTML of project owner in 'projects_list' and 'summary' views This for example allows to put email address in the project owner field in the projects index file (when $projects_list points to a file, and not to a directory), in the form of: path/to/repo.git Random+J+Developer+ Noticed-by: Jon Smirl Signed-off-by: Jakub Narebski Signed-off-by: Petr Baudis Signed-off-by: Junio C Hamano --- gitweb/gitweb.perl | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl index 18042843d6..b2bae1b250 100755 --- a/gitweb/gitweb.perl +++ b/gitweb/gitweb.perl @@ -3419,7 +3419,7 @@ sub git_project_list_body { "" . $cgi->a({-href => href(project=>$pr->{'path'}, action=>"summary"), -class => "list", -title => $pr->{'descr_long'}}, esc_html($pr->{'descr'})) . "\n" . - "" . chop_str($pr->{'owner'}, 15) . "\n"; + "" . esc_html(chop_str($pr->{'owner'}, 15)) . "\n"; print "{'age'}) . "\">" . (defined $pr->{'age_string'} ? $pr->{'age_string'} : "No commits") . "\n" . "" . @@ -3795,7 +3795,7 @@ sub git_summary { print "
 
\n"; print "\n" . "\n" . - "\n"; + "\n"; if (defined $cd{'rfc2822'}) { print "\n"; }
description" . esc_html($descr) . "
owner$owner
owner" . esc_html($owner) . "
last change$cd{'rfc2822'}