diff options
| author | Elijah Newren <newren@gmail.com> | 2025-03-19 16:22:58 +0000 |
|---|---|---|
| committer | Junio C Hamano <gitster@pobox.com> | 2025-03-21 03:32:10 -0700 |
| commit | 5633aa3af1282cad5161174f17867399e58b2a54 (patch) | |
| tree | c48ce7f4c1b215b9df553c61c8e4c300af51f3d9 /scalar.c | |
| parent | 85e4f762c224c52708919a10c9fa5b79e7949564 (diff) | |
| download | git-5633aa3af1282cad5161174f17867399e58b2a54.tar.gz | |
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 'scalar.c')
| -rw-r--r-- | scalar.c | 4 |
1 files changed, 2 insertions, 2 deletions
@@ -241,7 +241,7 @@ static int add_or_remove_enlistment(int add) static int start_fsmonitor_daemon(void) { - assert(have_fsmonitor_support()); + ASSERT(have_fsmonitor_support()); if (fsmonitor_ipc__get_state() != IPC_STATE__LISTENING) return run_git("fsmonitor--daemon", "start", NULL); @@ -251,7 +251,7 @@ static int start_fsmonitor_daemon(void) static int stop_fsmonitor_daemon(void) { - assert(have_fsmonitor_support()); + ASSERT(have_fsmonitor_support()); if (fsmonitor_ipc__get_state() == IPC_STATE__LISTENING) return run_git("fsmonitor--daemon", "stop", NULL); |
