aboutsummaryrefslogtreecommitdiffstats
path: root/builtin
diff options
context:
space:
mode:
authorJohannes Schindelin <johannes.schindelin@gmx.de>2025-03-27 11:52:55 +0000
committerJunio C Hamano <gitster@pobox.com>2025-03-28 17:38:08 -0700
commit38c696d66b9d3a8f4f3363cc4254dd130723f396 (patch)
treef9a19bcbc39144a3757332c6a311d8bb3f4260c5 /builtin
parentf569065fc4ea047e1b2b0d50d2a59d9987a050b3 (diff)
downloadgit-38c696d66b9d3a8f4f3363cc4254dd130723f396.tar.gz
rebase: avoid using the comma operator unnecessarily
The comma operator is a somewhat obscure C feature that is often used by mistake and can even cause unintentional code flow. Better use a semicolon instead. Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Acked-by: Phillip Wood <phillip.wood@dunelm.org.uk> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin')
-rw-r--r--builtin/rebase.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/rebase.c b/builtin/rebase.c
index d4715ed35d..62bdf7276f 100644
--- a/builtin/rebase.c
+++ b/builtin/rebase.c
@@ -1843,7 +1843,7 @@ int cmd_rebase(int argc,
strbuf_addf(&msg, "%s (start): checkout %s",
options.reflog_action, options.onto_name);
ropts.oid = &options.onto->object.oid;
- ropts.orig_head = &options.orig_head->object.oid,
+ ropts.orig_head = &options.orig_head->object.oid;
ropts.flags = RESET_HEAD_DETACH | RESET_ORIG_HEAD |
RESET_HEAD_RUN_POST_CHECKOUT_HOOK;
ropts.head_msg = msg.buf;