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>
Этот коммит содержится в:
родитель
86a6d358f7
Коммит
6d3c8bc37f
@ -63,7 +63,7 @@ static void add_entry(struct commit *commit, const char *host)
|
|||||||
html_attr(pageurl);
|
html_attr(pageurl);
|
||||||
if (ctx.cfg.virtual_root)
|
if (ctx.cfg.virtual_root)
|
||||||
delim = '?';
|
delim = '?';
|
||||||
htmlf("%cid=%s", delim, hex);
|
html_attrf("%cid=%s", delim, hex);
|
||||||
html("'/>\n");
|
html("'/>\n");
|
||||||
free(pageurl);
|
free(pageurl);
|
||||||
}
|
}
|
||||||
|
Загрузка…
Ссылка в новой задаче
Block a user