Move loading cryptors into objectProcessor init.
This commit is contained in:
parent
7ca18587c1
commit
e4488ba370
|
@ -32,7 +32,6 @@ import traceback
|
|||
import defaults
|
||||
# Network subsystem
|
||||
import network
|
||||
import shared
|
||||
import shutdown
|
||||
import state
|
||||
|
||||
|
@ -181,9 +180,6 @@ class Main(object):
|
|||
Inventory() # init
|
||||
|
||||
if state.enableObjProc: # Not needed if objproc is disabled
|
||||
shared.reloadMyAddressHashes()
|
||||
shared.reloadBroadcastSendersForWhichImWatching()
|
||||
|
||||
# Start the address generation thread
|
||||
addressGeneratorThread = addressGenerator()
|
||||
# close the main program even if there are threads left
|
||||
|
|
|
@ -44,12 +44,14 @@ class objectProcessor(threading.Thread):
|
|||
def __init__(self):
|
||||
threading.Thread.__init__(self, name="objectProcessor")
|
||||
random.seed()
|
||||
sql_ready.wait()
|
||||
shared.reloadMyAddressHashes()
|
||||
shared.reloadBroadcastSendersForWhichImWatching()
|
||||
# It may be the case that the last time Bitmessage was running,
|
||||
# the user closed it before it finished processing everything in the
|
||||
# objectProcessorQueue. Assuming that Bitmessage wasn't closed
|
||||
# forcefully, it should have saved the data in the queue into the
|
||||
# objectprocessorqueue table. Let's pull it out.
|
||||
sql_ready.wait()
|
||||
queryreturn = sqlQuery(
|
||||
'SELECT objecttype, data FROM objectprocessorqueue')
|
||||
for objectType, data in queryreturn:
|
||||
|
|
Reference in New Issue
Block a user