diff options
author | John Keeping <john@keeping.me.uk> | 2017-01-15 12:29:38 +0000 |
---|---|---|
committer | Lukas Fleischer <lfleischer@lfos.de> | 2017-08-10 15:15:54 +0200 |
commit | 7f7f91141ced1085dd2c6dbc5c65703d73b1b8c7 (patch) | |
tree | aaf89e31e591d14fe43a330f6e037473aba68448 | |
parent | d08d6fcb19bb5f008b34282fe59fed3acd93e67f (diff) | |
download | cgit-7f7f91141ced1085dd2c6dbc5c65703d73b1b8c7.tar.gz cgit-7f7f91141ced1085dd2c6dbc5c65703d73b1b8c7.tar.bz2 cgit-7f7f91141ced1085dd2c6dbc5c65703d73b1b8c7.zip |
ui-atom: properly escape delimiter in page link
If the delimiter here is '&' then it needs to be escaped for inclusion
in an attribute. Use html_attrf() to ensure that this happens (we know
that hex won't need escaping, but this makes it clearer what's
happening.
Signed-off-by: John Keeping <john@keeping.me.uk>
-rw-r--r-- | ui-atom.c | 2 |
1 files changed, 1 insertions, 1 deletions
@@ -63,7 +63,7 @@ static void add_entry(struct commit *commit, const char *host) html_attr(pageurl); if (ctx.cfg.virtual_root) delim = '?'; - htmlf("%cid=%s", delim, hex); + html_attrf("%cid=%s", delim, hex); html("'/>\n"); free(pageurl); } |