]> git.ipfire.org Git - thirdparty/git.git/commit
builtin/config: track "fixed value" option via flags only
authorPatrick Steinhardt <ps@pks.im>
Wed, 15 May 2024 06:43:02 +0000 (08:43 +0200)
committerJunio C Hamano <gitster@pobox.com>
Wed, 15 May 2024 14:17:56 +0000 (07:17 -0700)
commitab8bac8bb6d89f3b3eca2972ad468ca863c9f492
treea607fb70e5fe950c48c04b024dde02e1b40180c6
parent040b141df39a952af936abf73f4e2fa5fc9954b5
builtin/config: track "fixed value" option via flags only

We track the "fixed value" option via two separate bits: once via the
global variable `fixed_value`, and once via the CONFIG_FLAGS_FIXED_VALUE
bit in `flags`. This is confusing and may easily lead to issues when one
is not aware that this is tracked via two separate mechanisms.

Refactor the code to use the flag exclusively. We already pass it to all
the required callsites anyway, except for `collect_config()`.

Signed-off-by: Patrick Steinhardt <ps@pks.im>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
builtin/config.c