Commit 074336e
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 <[email protected]>
Reviewed-by: Stefan Beller <[email protected]>
Signed-off-by: Junio C Hamano <[email protected]>1 parent 706d5f8 commit 074336e
1 file changed
+6
-9
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
2259 | 2259 | | |
2260 | 2260 | | |
2261 | 2261 | | |
2262 | | - | |
2263 | 2262 | | |
2264 | 2263 | | |
2265 | 2264 | | |
| |||
2298 | 2297 | | |
2299 | 2298 | | |
2300 | 2299 | | |
2301 | | - | |
2302 | | - | |
2303 | | - | |
2304 | | - | |
2305 | | - | |
| 2300 | + | |
| 2301 | + | |
| 2302 | + | |
| 2303 | + | |
| 2304 | + | |
2306 | 2305 | | |
2307 | | - | |
| 2306 | + | |
2308 | 2307 | | |
2309 | 2308 | | |
2310 | 2309 | | |
| |||
2320 | 2319 | | |
2321 | 2320 | | |
2322 | 2321 | | |
2323 | | - | |
2324 | | - | |
2325 | 2322 | | |
2326 | 2323 | | |
2327 | 2324 | | |
| |||
0 commit comments