From a1b32fdc3d1d05395f186bfa06e92174519dab8d Mon Sep 17 00:00:00 2001 From: Junio C Hamano Date: Sun, 22 Jun 2008 00:21:28 -0700 Subject: [PATCH] git-rerere: detect unparsable conflicts rerere did not detect the case where <<< === >>> markers did not match. Signed-off-by: Junio C Hamano --- builtin-rerere.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/builtin-rerere.c b/builtin-rerere.c index 610b96a12..addc5c73d 100644 --- a/builtin-rerere.c +++ b/builtin-rerere.c @@ -144,6 +144,11 @@ static int handle_file(const char *path, fclose(out); if (sha1) SHA1_Final(sha1, &ctx); + if (hunk) { + if (output) + unlink(output); + return error("Could not parse conflict hunks in %s", path); + } return hunk_no; } -- 2.30.2