<feed xmlns='http://www.w3.org/2005/Atom'>
<title>cgit/html.c, branch v0.9</title>
<subtitle>A hyperfast web frontend for git repositories written in C.</subtitle>
<id>http://git.cetero.st/cgit/atom/html.c?h=v0.9</id>
<link rel='self' href='http://git.cetero.st/cgit/atom/html.c?h=v0.9'/>
<link rel='alternate' type='text/html' href='http://git.cetero.st/cgit/'/>
<updated>2011-03-05T13:01:59Z</updated>
<entry>
<title>Merge branch 'stable'</title>
<updated>2011-03-05T13:01:59Z</updated>
<author>
<name>Lars Hjemli</name>
<email>hjemli@gmail.com</email>
</author>
<published>2011-03-05T13:01:59Z</published>
<link rel='alternate' type='text/html' href='http://git.cetero.st/cgit/commit/?id=1b09cbd303d889ec2636127584d57b7f1b70c25e'/>
<id>urn:sha1:1b09cbd303d889ec2636127584d57b7f1b70c25e</id>
<content type='text'>
</content>
</entry>
<entry>
<title>do not infloop on a query ending in %XY, for invalid hex X or Y</title>
<updated>2011-03-05T12:38:34Z</updated>
<author>
<name>Jim Meyering</name>
<email>meyering@redhat.com</email>
</author>
<published>2011-02-28T11:18:57Z</published>
<link rel='alternate' type='text/html' href='http://git.cetero.st/cgit/commit/?id=fc384b16fb9787380746000d3cea2d53fccc548e'/>
<id>urn:sha1:fc384b16fb9787380746000d3cea2d53fccc548e</id>
<content type='text'>
When a query ends in say %gg, (or any invalid hex) e.g.,
http://git.gnome.org/browse/gdlmm/commit/?id=%gg
convert_query_hexchar calls memmove(txt, txt+3, 0), and then returns
txt-1, so the loop in http_parse_querystring never terminates.  The
solution is to make the memmove also copy the trailing NUL.
* html.c (convert_query_hexchar): Fix off-by-one error.

Signed-off-by: Lars Hjemli &lt;hjemli@gmail.com&gt;
</content>
</entry>
<entry>
<title>html.c: use '+' to escape spaces in urls</title>
<updated>2010-11-09T23:22:41Z</updated>
<author>
<name>Lars Hjemli</name>
<email>hjemli@gmail.com</email>
</author>
<published>2010-11-09T17:15:21Z</published>
<link rel='alternate' type='text/html' href='http://git.cetero.st/cgit/commit/?id=c2680325f68192368d32f26458fea9cfb50df6e5'/>
<id>urn:sha1:c2680325f68192368d32f26458fea9cfb50df6e5</id>
<content type='text'>
Signed-off-by: Lars Hjemli &lt;hjemli@gmail.com&gt;
</content>
</entry>
<entry>
<title>prefer html_raw() to write()</title>
<updated>2010-09-04T18:30:10Z</updated>
<author>
<name>Mark Lodato</name>
<email>lodatom@gmail.com</email>
</author>
<published>2010-09-04T18:18:16Z</published>
<link rel='alternate' type='text/html' href='http://git.cetero.st/cgit/commit/?id=d187b98557d91b874836f286b955ba76ab26fb02'/>
<id>urn:sha1:d187b98557d91b874836f286b955ba76ab26fb02</id>
<content type='text'>
To make the code more consistent, and to not rely on the implementation
of html(), always use html_raw(...) instead of write(htmlfd, ...).

Signed-off-by: Mark Lodato &lt;lodatom@gmail.com&gt;
</content>
</entry>
<entry>
<title>Merge branch 'stable'</title>
<updated>2010-08-29T15:40:51Z</updated>
<author>
<name>Lars Hjemli</name>
<email>hjemli@gmail.com</email>
</author>
<published>2010-08-29T15:40:51Z</published>
<link rel='alternate' type='text/html' href='http://git.cetero.st/cgit/commit/?id=6940b23b9e4698ba466a4616e4de77b986560ad3'/>
<id>urn:sha1:6940b23b9e4698ba466a4616e4de77b986560ad3</id>
<content type='text'>
</content>
</entry>
<entry>
<title>html: fix strcpy bug in convert_query_hexchar</title>
<updated>2010-08-29T15:27:40Z</updated>
<author>
<name>Mark Lodato</name>
<email>lodatom@gmail.com</email>
</author>
<published>2010-08-28T01:02:27Z</published>
<link rel='alternate' type='text/html' href='http://git.cetero.st/cgit/commit/?id=48434780ca62fde84337ea1e797f642de5ca50d5'/>
<id>urn:sha1:48434780ca62fde84337ea1e797f642de5ca50d5</id>
<content type='text'>
The source and destination strings in strcpy() may not overlap.
Instead, use memmove(), which allows overlap.  This fixes test t0104,
where 'url=foo%2bbar/tree' was being parsed improperly.

Signed-off-by: Mark Lodato &lt;lodatom@gmail.com&gt;
</content>
</entry>
<entry>
<title>html: properly percent-escape URLs</title>
<updated>2010-02-09T15:12:43Z</updated>
<author>
<name>Mark Lodato</name>
<email>lodatom@gmail.com</email>
</author>
<published>2010-02-09T15:12:43Z</published>
<link rel='alternate' type='text/html' href='http://git.cetero.st/cgit/commit/?id=a2c6355f9fdede78ce46aeee39ef649637aaadf9'/>
<id>urn:sha1:a2c6355f9fdede78ce46aeee39ef649637aaadf9</id>
<content type='text'>
The only valid characters for a URL are unreserved characters
a-zA-Z0-9_-.~ and the reserved characters !*'();:@&amp;=+$,/?%#[] , as per
RFC 3986.  Everything else must be escaped.  Additionally, the # and
? always have special meaning, and the &amp;, =, and + have special meaning
in a query string, so they too must be escaped.  To make this easier,
a table of escapes is now used so that we do not have to call fmt() for
each character; if the entry is 0, no escaping is needed.

Signed-off-by: Mark Lodato &lt;lodatom@gmail.com&gt;
</content>
</entry>
<entry>
<title>html: make all strings 'const char *'</title>
<updated>2010-02-09T04:04:41Z</updated>
<author>
<name>Mark Lodato</name>
<email>lodatom@gmail.com</email>
</author>
<published>2010-02-09T04:04:41Z</published>
<link rel='alternate' type='text/html' href='http://git.cetero.st/cgit/commit/?id=8aab27f24de70acfbdcee31c634a4b1facf23b92'/>
<id>urn:sha1:8aab27f24de70acfbdcee31c634a4b1facf23b92</id>
<content type='text'>
None of the html_* functions modify their argument, so they can all be
'const char *' instead of a simple 'char *'.  This removes the need to
cast (or copy) when trying to print a const string.

Signed-off-by: Mark Lodato &lt;lodatom@gmail.com&gt;
</content>
</entry>
<entry>
<title>html.c: use correct escaping in html attributes</title>
<updated>2009-01-29T21:21:15Z</updated>
<author>
<name>Lars Hjemli</name>
<email>hjemli@gmail.com</email>
</author>
<published>2009-01-29T21:21:15Z</published>
<link rel='alternate' type='text/html' href='http://git.cetero.st/cgit/commit/?id=7efcef00b5aadf22f5be80ecd7b736398cf7f6b4'/>
<id>urn:sha1:7efcef00b5aadf22f5be80ecd7b736398cf7f6b4</id>
<content type='text'>
First, an apostrophe is not a quote. Second, we also need to escape
quotes. And finally, quotes are encoded as '&amp;quot;', not '&amp;quote;'.

Sighned-off-by: Lars Hjemli &lt;hjemli@gmail.com&gt;
</content>
</entry>
<entry>
<title>html.c: add html_url_path</title>
<updated>2008-10-05T14:52:57Z</updated>
<author>
<name>Lars Hjemli</name>
<email>hjemli@gmail.com</email>
</author>
<published>2008-10-05T14:52:57Z</published>
<link rel='alternate' type='text/html' href='http://git.cetero.st/cgit/commit/?id=22a597e56dc7fdea78ccbcb7466b45dd62cf7b32'/>
<id>urn:sha1:22a597e56dc7fdea78ccbcb7466b45dd62cf7b32</id>
<content type='text'>
This function can be used to generate properly escaped path-components
for links.

Signed-off-by: Lars Hjemli &lt;hjemli@gmail.com&gt;
</content>
</entry>
</feed>
