From: Johannes Schindelin Date: Tue, 24 Jul 2007 00:03:26 +0000 (+0100) Subject: mailinfo: fix 'fatal: cannot convert from utf-8 to utf-8' X-Git-Tag: v1.5.3-rc3~20 X-Git-Url: https://git.tokkee.org/?a=commitdiff_plain;h=7296096c9d7e9fa12901c02fd1d12f4f996043e2;p=git.git mailinfo: fix 'fatal: cannot convert from utf-8 to utf-8' For some reason, I got this error message. Maybe it does not make sense, but then we should not really try to convert the text when it is not necessary. Signed-off-by: Johannes Schindelin Signed-off-by: Junio C Hamano --- diff --git a/builtin-mailinfo.c b/builtin-mailinfo.c index a37a4fff3..b4f6e913b 100644 --- a/builtin-mailinfo.c +++ b/builtin-mailinfo.c @@ -529,6 +529,8 @@ static void convert_to_utf8(char *line, const char *charset) return; } + if (!strcmp(metainfo_charset, charset)) + return; out = reencode_string(line, metainfo_charset, charset); if (!out) die("cannot convert from %s to %s\n",