summaryrefslogtreecommitdiff
path: root/sfeed_atom.c
diff options
context:
space:
mode:
authorHiltjo Posthuma <hiltjo@codemadness.org>2023-04-10 16:40:56 +0200
committerHiltjo Posthuma <hiltjo@codemadness.org>2023-04-10 16:40:56 +0200
commit14cce37fa54608362dc2d19ff66d10b64e5777b1 (patch)
tree3ff81472d2f40d47e61409bba14a78fc3593df2c /sfeed_atom.c
parenta15c98f32d8a768fee7b6783f7cea710cc5878a9 (diff)
sfeed_atom: in Atom the default for a type is text
Save a few bytes in the output by removing it. https://www.rfc-editor.org/rfc/rfc4287 3.1.1. The "type" Attribute The title is an atomTextConstruct.
Diffstat (limited to 'sfeed_atom.c')
-rw-r--r--sfeed_atom.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/sfeed_atom.c b/sfeed_atom.c
index 3ce5cf0..cfaeb5b 100644
--- a/sfeed_atom.c
+++ b/sfeed_atom.c
@@ -95,7 +95,7 @@ printfeed(FILE *fp, const char *feedname)
/* NOTE: an RSS/Atom viewer may or may not format
whitespace such as newlines.
Workaround: type="html" and <![CDATA[<pre></pre>]]> */
- fputs("\t<content type=\"text\">", stdout);
+ fputs("\t<content>", stdout);
}
printcontent(fields[FieldContent]);
fputs("</content>\n", stdout);
@@ -132,7 +132,7 @@ main(int argc, char *argv[])
fputs("<?xml version=\"1.0\" encoding=\"UTF-8\"?>\n"
"<feed xmlns=\"http://www.w3.org/2005/Atom\">\n"
- "\t<title type=\"text\">Newsfeed</title>\n"
+ "\t<title>Newsfeed</title>\n"
"\t<author><name>sfeed</name></author>\n", stdout);
printf("\t<id>urn:newsfeed:%lld</id>\n"
"\t<updated>%04d-%02d-%02dT%02d:%02d:%02dZ</updated>\n",