diff options
author | Russell Belfer <rb@github.com> | 2013-09-24 21:11:20 +0400 |
---|---|---|
committer | Russell Belfer <rb@github.com> | 2013-09-24 21:11:20 +0400 |
commit | 634f10f69090b325a50c8bca6cb303397576305e (patch) | |
tree | 7728cd252fd6377749b593654d88d89270a66a73 /src/crlf.c | |
parent | a3c2d916d8ad67196d2211b0a88dcbab7a433764 (diff) |
Fix incorrect return code in crlf filter
The git_buf_text_gather_stats call returns a boolean indicating if
the file looks like binary data. That shouldn't be an error; it
should be used to skip CRLF processing though.
Diffstat (limited to 'src/crlf.c')
-rw-r--r-- | src/crlf.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/src/crlf.c b/src/crlf.c index b4eda267b..b25c02cce 100644 --- a/src/crlf.c +++ b/src/crlf.c @@ -133,9 +133,9 @@ static int crlf_apply_to_odb( if (ca->crlf_action == GIT_CRLF_AUTO || ca->crlf_action == GIT_CRLF_GUESS) { git_buf_text_stats stats; - /* Check heuristics for binary vs text... */ + /* Check heuristics for binary vs text - returns true if binary */ if (git_buf_text_gather_stats(&stats, from, false)) - return -1; + return GIT_PASSTHROUGH; /* * We're currently not going to even try to convert stuff |