Conversation
laanwj
commented
Apr 23, 2014
- Add required locks in tests (fixes Unit tests failing with -DDEBUG_LOCKORDER #4084)
- Get required locks up-front in GUI updates and use a try_lock to skip when lock already held (fixes Deadlock on exit after low disk space during syncing #4083)
- Add missing AssertLockHeld in ConnectBlock (missed this externally-callable function in Solve chainActive-related locking issues #4058)
Unit tests with DEBUG_LOCKORDER were running into assertions.
This avoids the GUI from getting stuck on periodical polls if the core is holding the locks for a longer time - for example, during a wallet rescan.
|
Having fixed this I get a different exception (not related to locking) on shutdown now sometimes when I try to reproduce #4083, Traceback: |
|
Automatic sanity-testing: PASSED, see http://jenkins.bluematt.me/pull-tester/b39a07dc42ab6ba746a25206969fb81913146f1f for binaries and test log. |
|
That looks like the same issue I had when I ran master with 55a1db4 reverted. |
|
I think I know what happens:
Somehow it manages to process another message before the GUI thread detects that a shutdown is requested. The solution here would be to either not leave the view in an inconsistent state when failing, change the assertion to a normal error, and/or make sure that all message loops are exited when a fatal exception (such as disk full) occurs. In any case, it is not a problem with the changes in this pull, but a problem that existed before. |
|
ACK |