From: Salikh Zakirov Date: Sat, 27 May 2006 17:57:29 +0000 (+0400) Subject: Fixed Cygwin CR-munging problem in mailsplit X-Git-Tag: v1.4.0-rc1~27 X-Git-Url: https://git.verplant.org/?a=commitdiff_plain;h=347f1d2608471cbc64f1cf25943f8d6f89256d2c;p=git.git Fixed Cygwin CR-munging problem in mailsplit Do not open mailbox file as fopen(..., "rt") as this strips CR characters from the diff, thus breaking the patch context for changes in CRLF files. Signed-off-by: Salikh Zakirov Signed-off-by: Junio C Hamano --- diff --git a/mailsplit.c b/mailsplit.c index c529e2d0..70a569c1 100644 --- a/mailsplit.c +++ b/mailsplit.c @@ -162,7 +162,7 @@ int main(int argc, const char **argv) while (*argp) { const char *file = *argp++; - FILE *f = !strcmp(file, "-") ? stdin : fopen(file, "rt"); + FILE *f = !strcmp(file, "-") ? stdin : fopen(file, "r"); int file_done = 0; if ( !f )