Re: git diff returns fatal error with core.safecrlf is set to true.
- From
Torsten Bögershausen <tboegi@web.de>
- Date
- Jun 25, 2013, 20:29 UTC
- Message-ID
- <51C9FDC0.5020709@web.de>
- In-Reply-To
- <7vli5z6uyq.fsf@alter.siamese.dyndns.org>
Show 8 quoted lines
> +++ b/diff.c
> @@ -2647,6 +2647,10 @@ static int diff_populate_gitlink(struct diff_filespec *s, int size_only)
> int diff_populate_filespec(struct diff_filespec *s, int size_only)
> {
> int err = 0;
> + enum safe_crlf crlf_warn = (safe_crlf != SAFE_CRLF_FAIL
> + ? safe_crlf
> + : SAFE_CRLF_WARN);Thanks, Does it makes sense to write it the other way around?
enum safe_crlf crlf_warn = (safe_crlf == SAFE_CRLF_FAIL
? SAFE_CRLF_WARN
: safe_crlf);