builtin/gc: don't peek into `struct lock_file`
authorMartin Ågren <redacted>
Tue, 5 Jan 2021 19:23:46 +0000 (20:23 +0100)
committerJunio C Hamano <redacted>
Wed, 6 Jan 2021 21:53:32 +0000 (13:53 -0800)
commitd4a497664875c84c4ab8318625bb8881508ac18a
tree848c96bd9fe84614f1cf7865273d83c6bdfb53e6
parent71ca53e8125e36efbda17293c50027d31681a41f
builtin/gc: don't peek into `struct lock_file`

A `struct lock_file` is pretty much just a wrapper around a tempfile.
But it's easy enough to avoid relying on this. Use the wrappers that the
lock file API provides rather than peeking at the temp file or even into
*its* internals.

Signed-off-by: Martin Ågren <redacted>
Reviewed-by: Derrick Stolee <redacted>
Signed-off-by: Junio C Hamano <redacted>
builtin/gc.c
git clone https://git.99rst.org/PROJECT