summaryrefslogtreecommitdiff
path: root/log-tree.c
diff options
context:
space:
mode:
authorSergey Organov <sorganov@gmail.com>2020-08-28 14:05:26 +0300
committerJunio C Hamano <gitster@pobox.com>2020-09-06 10:33:19 -0700
commit793d37c17ffab46507e14c4547ad2edc9ba9e3fe (patch)
tree85ede32178a498a293a50839f533aea5ee2f1b65 /log-tree.c
parenta7b94309406c8f713a061ca8b930179483b12619 (diff)
downloadgit-793d37c17ffab46507e14c4547ad2edc9ba9e3fe.tar.gz
log_tree_diff: get rid of extra check for NULL
Get rid of needless check of 'parents' for NULL. The NULL case is already handled right above, and 'parents' is dereferenced without check below anyway. Signed-off-by: Sergey Organov <sorganov@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'log-tree.c')
-rw-r--r--log-tree.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/log-tree.c b/log-tree.c
index c01932fa72..8ac285a25a 100644
--- a/log-tree.c
+++ b/log-tree.c
@@ -917,7 +917,7 @@ static int log_tree_diff(struct rev_info *opt, struct commit *commit, struct log
}
/* More than one parent? */
- if (parents && parents->next) {
+ if (parents->next) {
if (opt->ignore_merges)
return 0;
else if (opt->combine_merges)