]> git.ipfire.org Git - thirdparty/git.git/commit
add: use unsigned type for collection of bits
authorEugenio Gigante <giganteeugenio2@gmail.com>
Thu, 29 Feb 2024 19:44:44 +0000 (20:44 +0100)
committerJunio C Hamano <gitster@pobox.com>
Thu, 29 Feb 2024 19:52:42 +0000 (11:52 -0800)
commit322320445630570539f7b55f376e3431f49c8405
tree65109831c27cf8a6c8ad0c63bda42c8b9741ee0d
parent0d464a4e6a5a19bd8fbea1deae22d48d14dccb01
add: use unsigned type for collection of bits

The 'refresh' function in 'builtin/add.c' declares 'flags' as
signed, and passes it as an argument to the 'refresh_index'
function, which though expects an unsigned value.

Since in this case 'flags' represents a bag of bits, whose MSB is
not used in special ways, change the type of 'flags' to unsigned.

Signed-off-by: Eugenio Gigante <giganteeugenio2@gmail.com>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/add.c