projects
/
citadel.git
/ commitdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
| commitdiff |
tree
raw
|
patch
|
inline
| side by side (parent:
efb97b0
)
Reorganized portions of html2html.c
author
Art Cancro
<ajc@citadel.org>
Sat, 4 Feb 2006 17:50:05 +0000
(17:50 +0000)
committer
Art Cancro
<ajc@citadel.org>
Sat, 4 Feb 2006 17:50:05 +0000
(17:50 +0000)
webcit/html2html.c
patch
|
blob
|
history
diff --git
a/webcit/html2html.c
b/webcit/html2html.c
index 00a2adcbb9301260c93462cac4515b6ea11dd3b2..31531f3a01c1b0767ea13c1ec24178c38ecb04d9 100644
(file)
--- a/
webcit/html2html.c
+++ b/
webcit/html2html.c
@@
-237,14
+237,18
@@
void output_html(char *supplied_charset, int treat_as_wiki) {
}
#endif
}
#endif
- /** FIXME At this point, shigerugo's messages are still clean.
- * Figure out what is mangling them below.
+ /**
+ * At this point, the message has been stripped down to
+ * only the content inside the <BODY></BODY> tags, and has
+ * been converted to UTF-8 if it was originally in a foreign
+ * character set. The text is also guaranteed to be null
+ * terminated now.
*/
/** Now go through the message, parsing tags as necessary. */
converted_msg = malloc(content_length);
strcpy(converted_msg, "");
*/
/** Now go through the message, parsing tags as necessary. */
converted_msg = malloc(content_length);
strcpy(converted_msg, "");
- ptr = msg
start
;
+ ptr = msg;
while (ptr < msgend) {
/**
* Change mailto: links to WebCit mail, by replacing the
while (ptr < msgend) {
/**
* Change mailto: links to WebCit mail, by replacing the
@@
-346,6
+350,10
@@
void output_html(char *supplied_charset, int treat_as_wiki) {
}
}
}
}
+ /** uncomment these two lines to override conversion */
+ /** memcpy(converted_msg, msg, content_length); */
+ /** output_length = content_length; */
+
/** Output our big pile of markup */
client_write(converted_msg, output_length);
/** Output our big pile of markup */
client_write(converted_msg, output_length);