* override a possibly user-customized format.pretty that would render git
log output unparsable by git range-diff
* don't use negative string precision, e.g. "%.*s", -5, "foo"
Changes since v1:
* Fixed a typo in the commit message (found by Taylor Blau)
Vasil Dimov (2):
range-diff: fix a crash in parsing git-log output
range-diff: avoid negative string precision
range-diff.c | 18 +++++++++++++++++-
t/t3206-range-diff.sh | 10 ++++++++++
2 files changed, 27 insertions(+), 1 deletion(-)
base-commit: de49261b050d9cd8ec73842356077bc5b606640f
Published-As: https://github.com/gitgitgadget/git/releases/tag/pr-git-760%2Fvasild%2Frange-diff-v2
Fetch-It-Via: git fetch https://github.com/gitgitgadget/git pr-git-760/vasild/range-diff-v2
Pull-Request: https://github.com/git/git/pull/760
Range-diff vs v1:
1: 2375e34100e = 1: 2375e34100e range-diff: fix a crash in parsing git-log output
2: b3384880c72 ! 2: 72fddcff554 range-diff: avoid negative string precision
@@ Metadata
## Commit message ##
range-diff: avoid negative string precision
- If the supplied integer for "precisoin" is negative in
+ If the supplied integer for "precision" is negative in
`"%.*s", len, line` then it is ignored. So the current code is
equivalent to just `"%s", line` because it is executed only if
`len` is negative.