util: disinfect lookup_reg strings (issue1126)
lookup_reg could return Unicode strings, which would infect other strings and
generate unexpected tracebacks. Spotted by Rémy Roy.
Fold in silly nested function while we're at it.
#header#
<title>#repo|escape# Changelog</title>
<description>#repo|escape# Changelog</description>
#entries%changelogentry#
</channel>
</rss>