aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorGravatar Jonathan Bastien-Filiatrault <joe@x2a.org>2007-10-27 07:13:41 (JST)
committerGravatar Jonathan Bastien-Filiatrault <joe@x2a.org>2007-11-06 08:13:31 (JST)
commit7858a309d7671109950ec940f893c2d112d36b99 (patch)
tree676723bafc103e232341aa05be4d57ed773b9feb
parentaf0819830445e39584a0137034562086a55deaf2 (diff)
downloadcgit-7858a309d7671109950ec940f893c2d112d36b99.zip
cgit-7858a309d7671109950ec940f893c2d112d36b99.tar.gz
Convert subject and message with iconv_msg.
-rw-r--r--parsing.c14
1 files changed, 14 insertions, 0 deletions
diff --git a/parsing.c b/parsing.c
index f156c12..c731084 100644
--- a/parsing.c
+++ b/parsing.c
@@ -320,6 +320,20 @@ struct commitinfo *cgit_parse_commit(struct commit *commit)
320 } else 320 } else
321 ret->subject = substr(p, p+strlen(p)); 321 ret->subject = substr(p, p+strlen(p));
322 322
323 if(strcmp(ret->msg_encoding, PAGE_ENCODING)) {
324 t = iconv_msg(ret->subject, ret->msg_encoding);
325 if(t) {
326 free(ret->subject);
327 ret->subject = t;
328 }
329
330 t = iconv_msg(ret->msg, ret->msg_encoding);
331 if(t) {
332 free(ret->msg);
333 ret->msg = t;
334 }
335 }
336
323 return ret; 337 return ret;
324} 338}
325 339