fix a deadlock

When finishedLiveUpdate was run on a different key than expected, it
blocked forever waiting for an indication the database had been updated.

Since the journal is locked when finishedLiveUpdate runs, this could
also have caused other git-annex commands to hang.
This commit is contained in:
Joey Hess 2024-08-27 00:13:54 -04:00
parent 21608716bd
commit 521e0a7062
No known key found for this signature in database
GPG key ID: DB12DB0FF05F8F38
2 changed files with 12 additions and 12 deletions

View file

@ -39,8 +39,7 @@ data LiveUpdate
{ liveUpdateNeeded :: MVar ()
, liveUpdateStart :: MVar ()
, liveUpdateReady :: MVar ()
, liveUpdateDone :: MVar (Maybe (UUID, Key, SizeChange))
, liveUpdateFinish :: MVar ()
, liveUpdateDone :: MVar (Maybe (UUID, Key, SizeChange, MVar ()))
}
| NoLiveUpdate