gc.sh: refactor lock_gc function for reuse
commit1021f3f33d607b689a1050db0e0f1111751bf75c
authorKyle J. McKay <mackyle@gmail.com>
Wed, 10 Jun 2020 18:45:58 +0000 (10 11:45 -0700)
committerKyle J. McKay <mackyle@gmail.com>
Wed, 10 Jun 2020 18:45:58 +0000 (10 11:45 -0700)
tree39146ae49e60d65ce7a0f304ea2233ffeb8fb661
parent61f41dde199da137067ab4f97c4e91ae93d739f2
gc.sh: refactor lock_gc function for reuse

Split the `lock_gc` function into two parts:

 1) a new `v_lock_gc` function that always returns
    and is reusable

 2) a minimal `lock_gc` function that calls the new
    function and provides behavior identical to
    the previous incarnation of the `lock_gc` function

Signed-off-by: Kyle J. McKay <mackyle@gmail.com>
jobd/gc.sh