From 6e9d9b07e2066fa7cf6506a9f4924ba98b8d1c2e Mon Sep 17 00:00:00 2001 From: Hiltjo Posthuma Date: Thu, 8 May 2014 12:03:22 +0000 Subject: sfeed: style, comments above Signed-off-by: Hiltjo Posthuma --- sfeed.c | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/sfeed.c b/sfeed.c index e1ec405..f9092b4 100644 --- a/sfeed.c +++ b/sfeed.c @@ -74,7 +74,8 @@ static XMLParser parser; /* XML parser state */ static char *append = NULL; /* append string after each output line */ /* TODO: optimize lookup */ -static int /* unique number for parsed tag (faster comparison) */ +/* unique number for parsed tag (faster comparison) */ +static int gettag(int feedtype, const char *name, size_t namelen) { /* RSS, alphabetical order */ static FeedTag rsstag[] = { @@ -277,7 +278,8 @@ cleanup(void) { string_free(&ctx.item.author); } -static void /* print error message to stderr */ +/* print error message to stderr */ +static void die(const char *s) { fputs("sfeed: ", stderr); fputs(s, stderr); @@ -507,7 +509,7 @@ xml_handler_attr(XMLParser *p, const char *tag, size_t taglen, static void xml_handler_start_element(XMLParser *p, const char *name, size_t namelen) { if(ctx.iscontenttag) { - /* starts with div, handle as XML, dont convert entities */ + /* starts with div, handle as XML, don't convert entities */ /* TODO: test properly */ if(ctx.item.feedtype == FeedTypeAtom && !strncmp(name, "div", strlen("div"))) -- cgit v1.2.3