diff options
author | Junio C Hamano <gitster@pobox.com> | 2024-08-14 23:54:55 +0200 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2024-08-14 23:54:55 +0200 |
commit | 494c9788e40dab99492f10658852010f4a31d358 (patch) | |
tree | fae63c45af76f374c65668df9cd257573e555777 /reflog.c | |
parent | Merge branch 'jr/ls-files-expand-literal-doc' (diff) | |
parent | Revert "reflog expire: don't use lookup_commit_reference_gently()" (diff) | |
download | git-494c9788e40dab99492f10658852010f4a31d358.tar.xz git-494c9788e40dab99492f10658852010f4a31d358.zip |
Merge branch 'jc/reflog-expire-lookup-commit-fix'
"git reflog expire" failed to honor annotated tags when computing
reachable commits.
* jc/reflog-expire-lookup-commit-fix:
Revert "reflog expire: don't use lookup_commit_reference_gently()"
Diffstat (limited to 'reflog.c')
-rw-r--r-- | reflog.c | 3 |
1 files changed, 2 insertions, 1 deletions
@@ -332,7 +332,8 @@ void reflog_expiry_prepare(const char *refname, if (!cb->cmd.expire_unreachable || is_head(refname)) { cb->unreachable_expire_kind = UE_HEAD; } else { - commit = lookup_commit(the_repository, oid); + commit = lookup_commit_reference_gently(the_repository, + oid, 1); if (commit && is_null_oid(&commit->object.oid)) commit = NULL; cb->unreachable_expire_kind = commit ? UE_NORMAL : UE_ALWAYS; |