summaryrefslogtreecommitdiff
path: root/git-commit-script
diff options
context:
space:
mode:
authorJohannes Schindelin <johannes.schindelin@gmx.de>2026-07-10 11:39:31 +0000
committerJunio C Hamano <gitster@pobox.com>2026-07-10 08:13:54 -0700
commite87d701dc69a6b194f223f2405102cae4c4af03b (patch)
treef9880315614b134f46bc8f35ad85a45c31f5b15f /git-commit-script
parent74fb18824cda5f28811e5d5e4653434f01238133 (diff)
replay: die when --onto does not peel to a commit
The `peel_committish()` function calls `repo_peel_to_type()` to convert the given object to a commit, but does not check the return value. When the object exists but cannot be peeled to a commit (e.g., a tree or blob OID is passed as --onto), the return value is NULL. Add an explicit NULL check and die with a descriptive message in that case. Pointed out by Coverity. Assisted-by: Claude Opus 4.6 Signed-off-by: Johannes Schindelin <johannes.schindelin@gmx.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'git-commit-script')
0 files changed, 0 insertions, 0 deletions