mirror of
https://github.com/bitcoin/bitcoin.git
synced 2026-03-05 19:26:17 +00:00
test: avoid interface_ipc.py race and null pointer dereference
Avoid race condition in run_deprecated_mining_test caused by creating and immediately destroying an unused worker thread. This leads to test failures reported by maflcko in #34711
This commit is contained in:
parent
9cad97f6cd
commit
1c1de334e9
@ -71,7 +71,9 @@ class IPCInterfaceTest(BitcoinTestFramework):
|
||||
def run_deprecated_mining_test(self):
|
||||
self.log.info("Running deprecated mining interface test")
|
||||
async def async_routine():
|
||||
ctx, init = await make_capnp_init_ctx(self)
|
||||
node = self.nodes[0]
|
||||
connection = await capnp.AsyncIoStream.create_unix_connection(node.ipc_socket_path)
|
||||
init = capnp.TwoPartyClient(connection).bootstrap().cast_as(self.capnp_modules['init'].Init)
|
||||
self.log.debug("Calling deprecated makeMiningOld2 should raise an error")
|
||||
try:
|
||||
await init.makeMiningOld2()
|
||||
|
||||
Loading…
x
Reference in New Issue
Block a user