aboutsummaryrefslogtreecommitdiffstats
path: root/diff.c
diff options
context:
space:
mode:
authorÆvar Arnfjörð Bjarmason <avarab@gmail.com>2022-11-21 14:26:55 -0500
committerJunio C Hamano <gitster@pobox.com>2022-11-22 10:13:54 +0900
commit40286ca2fa1e08c386ea7bc6b76616a3cac63ffd (patch)
treece8f4f6cdab16cff74902780d997f5625a5ad226 /diff.c
parentparse_object(): check on-disk type of suspected blob (diff)
downloadgit-40286ca2fa1e08c386ea7bc6b76616a3cac63ffd.tar.gz
git-40286ca2fa1e08c386ea7bc6b76616a3cac63ffd.zip
parse_object(): simplify blob conditional
Commit 8db2dad7a0 (parse_object(): check on-disk type of suspected blob, 2022-11-17) simplified the conditional for checking if we might have a blob. But we can simplify it further. In: !obj || (obj && obj->type == OBJ_BLOB) the short-circuit "OR" means "obj" will always be true on the right-hand side. The compiler almost certainly optimized that out anyway, but dropping it makes the conditional easier to understand for humans. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'diff.c')
0 files changed, 0 insertions, 0 deletions