aboutsummaryrefslogtreecommitdiffstats
path: root/merge-recursive.c
diff options
context:
space:
mode:
authorElijah Newren <newren@gmail.com>2025-03-19 16:22:58 +0000
committerJunio C Hamano <gitster@pobox.com>2025-03-21 03:32:10 -0700
commit5633aa3af1282cad5161174f17867399e58b2a54 (patch)
treec48ce7f4c1b215b9df553c61c8e4c300af51f3d9 /merge-recursive.c
parentci: add build checking for side-effects in assert() calls (diff)
downloadgit-5633aa3af1282cad5161174f17867399e58b2a54.tar.gz
git-5633aa3af1282cad5161174f17867399e58b2a54.zip
treewide: replace assert() with ASSERT() in special cases
When the compiler/linker cannot verify that an assert() invocation is free of side effects for us (e.g. because the assertion includes some kind of function call), replace the use of assert() with ASSERT(). Signed-off-by: Elijah Newren <newren@gmail.com> Acked-by: Taylor Blau <me@ttaylorr.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'merge-recursive.c')
-rw-r--r--merge-recursive.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/merge-recursive.c b/merge-recursive.c
index 884ccf99a5..4fbbece922 100644
--- a/merge-recursive.c
+++ b/merge-recursive.c
@@ -1197,7 +1197,7 @@ static void print_commit(struct repository *repo, struct commit *commit)
struct pretty_print_context ctx = {0};
ctx.date_mode.type = DATE_NORMAL;
/* FIXME: Merge this with output_commit_title() */
- assert(!merge_remote_util(commit));
+ ASSERT(!merge_remote_util(commit));
repo_format_commit_message(repo, commit, " %h: %m %s", &sb, &ctx);
fprintf(stderr, "%s\n", sb.buf);
strbuf_release(&sb);