format-patch: do not wrap non-rfc2047 headers too early
commit7a76e68a177720da65e7d9cfa49d702a55e2d9de
authorJan H. Schönherr <schnhrr@cs.tu-berlin.de>
Thu, 18 Oct 2012 14:43:29 +0000 (18 16:43 +0200)
committerJunio C Hamano <gitster@pobox.com>
Thu, 18 Oct 2012 21:23:12 +0000 (18 14:23 -0700)
treee8d03be40b9710b0887c4836fea465c56b30d7f8
parent14e1a4e1ff70aff36db3f5d2a8b806efd0134d50
format-patch: do not wrap non-rfc2047 headers too early

Do not wrap the second and later lines of non-rfc2047-encoded headers
substantially before the 78 character limit.

Instead of passing the remaining length of the first line as wrapping
width, use the correct maximum length and tell strbuf_add_wrapped_bytes()
how many characters of the first line are already used.

Signed-off-by: Jan H. Schönherr <schnhrr@cs.tu-berlin.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
pretty.c
t/t4014-format-patch.sh