fix subprocesspow keyboard interrupt not being catched
parent
308fca7c22
commit
02fde0ad70
|
@ -116,8 +116,11 @@ class SubprocessPOW:
|
||||||
|
|
||||||
while True:
|
while True:
|
||||||
# Break if shutdown received
|
# Break if shutdown received
|
||||||
|
try:
|
||||||
if pipe.poll() and pipe.recv() == 'shutdown':
|
if pipe.poll() and pipe.recv() == 'shutdown':
|
||||||
break
|
break
|
||||||
|
except KeyboardInterrupt:
|
||||||
|
break
|
||||||
# Load nonce into block metadata
|
# Load nonce into block metadata
|
||||||
metadata['pow'] = nonce
|
metadata['pow'] = nonce
|
||||||
# Serialize metadata, combine with block data
|
# Serialize metadata, combine with block data
|
||||||
|
|
Loading…
Reference in New Issue