mirror of
https://git.zx2c4.com/cgit
synced 2024-11-22 08:28:42 +00:00
Convert subject and message with iconv_msg.
This commit is contained in:
parent
af08198304
commit
7858a309d7
14
parsing.c
14
parsing.c
@ -320,6 +320,20 @@ struct commitinfo *cgit_parse_commit(struct commit *commit)
|
|||||||
} else
|
} else
|
||||||
ret->subject = substr(p, p+strlen(p));
|
ret->subject = substr(p, p+strlen(p));
|
||||||
|
|
||||||
|
if(strcmp(ret->msg_encoding, PAGE_ENCODING)) {
|
||||||
|
t = iconv_msg(ret->subject, ret->msg_encoding);
|
||||||
|
if(t) {
|
||||||
|
free(ret->subject);
|
||||||
|
ret->subject = t;
|
||||||
|
}
|
||||||
|
|
||||||
|
t = iconv_msg(ret->msg, ret->msg_encoding);
|
||||||
|
if(t) {
|
||||||
|
free(ret->msg);
|
||||||
|
ret->msg = t;
|
||||||
|
}
|
||||||
|
}
|
||||||
|
|
||||||
return ret;
|
return ret;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user