From: Alexander Kurz <alexander.kurz@heliocentris.com>
To: <git@vger.kernel.org>
Subject: [PATCH] Fix: Handle ampersand in branch names properly
Date: Thu, 10 Oct 2013 16:19:55 +0200 [thread overview]
Message-ID: <5256B78B.6050801@heliocentris.com> (raw)
[-- Attachment #1: Type: text/plain, Size: 207 bytes --]
Hello git maintainer crew,
recently I stumbled about gitweb generating improper HTML after
somebody merged from a branch contining an ampersand, e.g. branch
name=fixes&features.
Thanks, Alexander Kurz
[-- Attachment #2: 0001-Fix-Handle-ampersand-in-branch-names-properly.patch --]
[-- Type: text/x-diff, Size: 717 bytes --]
>From beccd85ba8b8421213056883f31365f33d6e4490 Mon Sep 17 00:00:00 2001
From: kurz <kurz@DP-KURZ.heliocentris.com>
Date: Thu, 10 Oct 2013 16:09:46 +0200
Subject: [PATCH] Fix: Handle ampersand in branch names properly
---
gitweb/gitweb.perl | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gitweb/gitweb.perl b/gitweb/gitweb.perl
index 68c77f6..2963b1d 100755
--- a/gitweb/gitweb.perl
+++ b/gitweb/gitweb.perl
@@ -2026,7 +2026,7 @@ sub format_ref_marker {
-href => href(
action=>$dest_action,
hash=>$dest
- )}, $name);
+ )}, esc_attr($name));
$markers .= " <span class=\"".esc_attr($class)."\" title=\"".esc_attr($ref)."\">" .
$link . "</span>";
--
1.7.10.4
reply other threads:[~2013-10-10 14:20 UTC|newest]
Thread overview: [no followups] expand[flat|nested] mbox.gz Atom feed
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=5256B78B.6050801@heliocentris.com \
--to=alexander.kurz@heliocentris.com \
--cc=git@vger.kernel.org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
* If your mail client supports setting the In-Reply-To header
via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is an external index of several public inboxes,
see mirroring instructions on how to clone and mirror
all data and code used by this external index.