lock_ref_sha1_basic(): do not set force_write for missing references
authorMichael Haggerty <redacted>
Mon, 2 Mar 2015 09:29:53 +0000 (10:29 +0100)
committerJunio C Hamano <redacted>
Thu, 5 Mar 2015 20:35:36 +0000 (12:35 -0800)
commit074336e5ed4ff10577f22c6812e092e3f6607405
tree3d9efa59a808ca5a226f679454e9640b94a3a092
parent706d5f816fbcb1299c19f4d41bea60f1e229165e
lock_ref_sha1_basic(): do not set force_write for missing references

If a reference is missing, its SHA-1 will be null_sha1, which can't
possibly match a new value that ref_transaction_commit() is trying to
update it to. So there is no need to set force_write in this scenario.

Signed-off-by: Michael Haggerty <redacted>
Reviewed-by: Stefan Beller <redacted>
Signed-off-by: Junio C Hamano <redacted>
refs.c
git clone https://git.99rst.org/PROJECT