From: Junio C Hamano Date: Fri, 12 Jan 2007 22:11:39 GMT Subject: Re: [PATCH] Reencode committer info to utf-8 before formatting mail header Message-ID: <7vd55jrj38.fsf@assigned-by-dhcp.cox.net> In-Reply-To: <871wm08kcu.fsf@morpheus.local> David Kågedal writes: > The add_user_info function formats the commit as a mail message, and > uses add_rfc2047 to format the From: line. The add_rfc2047 assumes > that the string is encoded as utf-8. pretty_print_commit() labels the commit log message not just the author name also as UTF-8 when doing plain_non_ascii. It might make more sense to just set the log_output_encoding to be always UTF-8 when generating an e-mail output, in git-format-patch. > diff --git a/utf8.h b/utf8.h > index a07c5a8..eb64d46 100644 > --- a/utf8.h > +++ b/utf8.h > @@ -8,7 +8,7 @@ int is_encoding_utf8(const char *name); > void print_wrapped_text(const char *text, int indent, int indent2, int len); > > #ifndef NO_ICONV > -char *reencode_string(const char *in, const char *out_encoding, const char *in_encoding); > +char *reencode_string(const char *in, const char *out_encoding, const char *in_encoding, int *len); > #else > #define reencode_string(a,b,c) NULL > #endif This feels fishy...