aboutsummaryrefslogtreecommitdiff
path: root/qa/rpc-tests/p2p-compactblocks.py
diff options
context:
space:
mode:
authorWladimir J. van der Laan <laanwj@gmail.com>2016-11-18 13:08:30 +0100
committerMarcoFalke <falke.marco@gmail.com>2016-11-19 23:24:35 +0100
commitdccdc3aa34218eecd4a37988857b5d4f3dd884ef (patch)
tree3593c750b314b54b53d9e47e158a4e1a7eb4e4b6 /qa/rpc-tests/p2p-compactblocks.py
parentda4926b1d28c600076d3eb35df60981298194697 (diff)
downloadbitcoin-dccdc3aa34218eecd4a37988857b5d4f3dd884ef.tar.xz
test: Fix use-after-free in scheduler tests
Make a copy of the boost time-point to wait for, otherwise the head of the queue may be deleted by another thread while this one is waiting, while the boost function still has a reference to it. Although this problem is in non-test code, this is not an actual problem outside of the tests because we use the thread scheduler with only one service thread, so there will never be threads fighting at the head of the queue. The old boost fallback escapes this problem because it passes a scalar value to wait_until instead of a const object reference. Found by running the tests in LLVM-4.0-master asan. Github-Pull: #9186 Rebased-From: 12519bf62b8c49b1c1744eca6ea5b3162a61f962
Diffstat (limited to 'qa/rpc-tests/p2p-compactblocks.py')
0 files changed, 0 insertions, 0 deletions