From 91521b9da4337f6d7f5dc29b02fb04cf7f0ccd02 Mon Sep 17 00:00:00 2001 From: Jonas Fonseca Date: Wed, 10 Oct 2007 16:49:28 +0200 Subject: [PATCH] Fix crash when opening mergetool for lines that are not unmerged --- tig.c | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/tig.c b/tig.c index a3cebbf..06c3d04 100644 --- a/tig.c +++ b/tig.c @@ -3533,6 +3533,10 @@ status_request(struct view *view, enum request request, struct line *line) break; case REQ_STATUS_MERGE: + if (!status || status->status != 'U') { + report("Merging only possible for files with unmerged status ('U')."); + return REQ_NONE; + } open_mergetool(status->name); break; -- 2.30.2