diff options
author | Ævar Arnfjörð Bjarmason <avarab@gmail.com> | 2021-12-28 16:28:49 +0300 |
---|---|---|
committer | Junio C Hamano <gitster@pobox.com> | 2021-12-31 00:05:29 +0300 |
commit | 9ce6000cb7a023e16ae1743df760edaae1c5ca1d (patch) | |
tree | 15c805ed2a6435e25ef39b2a842dab6be49750e9 /builtin/cat-file.c | |
parent | 57d6a1cf967e82c5cb51d0950c1ed7d1b0916fe8 (diff) |
object-name.c: don't have GET_OID_ONLY_TO_DIE imply *_QUIETLY
Stop having GET_OID_ONLY_TO_DIE imply GET_OID_QUIETLY in
get_oid_with_context_1().
The *_DIE flag was added in 33bd598c390 (sha1_name.c: teach lookup
context to get_sha1_with_context(), 2012-07-02), and then later
tweaked in 7243ffdd78d (get_sha1: avoid repeating ourselves via
ONLY_TO_DIE, 2016-09-26).
Everything in that commit makes sense, but only for callers that
expect to fail in an initial call to get_oid_with_context_1(), e.g. as
"git show 0017" does via handle_revision_arg(), and then would like to
call get_oid_with_context_1() again via this
maybe_die_on_misspelt_object_name() function.
In the subsequent commit we'll add a new caller that expects to call
this only once, but who would still like to have all the error
messaging that GET_OID_ONLY_TO_DIE gives it, in addition to any
regular errors.
Signed-off-by: Ævar Arnfjörð Bjarmason <avarab@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'builtin/cat-file.c')
0 files changed, 0 insertions, 0 deletions