aboutsummaryrefslogtreecommitdiffstats
path: root/reftable/basics_test.c
diff options
context:
space:
mode:
authorKoji Nakamaru <koji.nakamaru@gree.net>2024-05-15 19:21:07 +0000
committerJunio C Hamano <gitster@pobox.com>2024-05-15 14:02:45 -0700
commite1ab45b2dab51f94db9548666dfd7af626d2aa7e (patch)
tree1498c8e94e6a8732dbdba6349b515c1ac7f6f216 /reftable/basics_test.c
parentosxkeychain: exclusive lock to serialize execution of operations (diff)
downloadgit-e1ab45b2dab51f94db9548666dfd7af626d2aa7e.tar.gz
git-e1ab45b2dab51f94db9548666dfd7af626d2aa7e.zip
osxkeychain: state to skip unnecessary store operations
git passes a credential that has been used successfully to the helpers to record. If a credential is already stored, "git-credential-osxkeychain store" just records the credential returned by "git-credential-osxkeychain get", and unnecessary (sometimes problematic) SecItemAdd() and/or SecItemUpdate() are performed. We can skip such unnecessary operations by marking a credential returned by "git-credential-osxkeychain get". This marking can be done by utilizing the "state[]" feature: - The "get" command sets the field "state[]=osxkeychain:seen=1". - The "store" command skips its actual operation if the field "state[]=osxkeychain:seen=1" exists. Introduce a new state "state[]=osxkeychain:seen=1". Suggested-by: brian m. carlson <sandals@crustytoothpaste.net> Signed-off-by: Koji Nakamaru <koji.nakamaru@gree.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'reftable/basics_test.c')
0 files changed, 0 insertions, 0 deletions