mirror of
https://github.com/dashpay/dash.git
synced 2024-12-25 12:02:48 +01:00
Set to nullptr after delete
This commit is contained in:
parent
fcf556f7e9
commit
d93b97fbcf
@ -482,6 +482,7 @@ void StopHTTPServer()
|
||||
LogPrint("http", "Waiting for HTTP worker threads to exit\n");
|
||||
workQueue->WaitExit();
|
||||
delete workQueue;
|
||||
workQueue = nullptr;
|
||||
}
|
||||
if (eventBase) {
|
||||
LogPrint("http", "Waiting for HTTP event thread to exit\n");
|
||||
|
@ -141,6 +141,7 @@ BOOST_AUTO_TEST_CASE(existing_data_no_obfuscate)
|
||||
|
||||
// Call the destructor to free leveldb LOCK
|
||||
delete dbw;
|
||||
dbw = nullptr;
|
||||
|
||||
// Now, set up another wrapper that wants to obfuscate the same directory
|
||||
CDBWrapper odbw(ph, (1 << 10), false, false, true);
|
||||
@ -182,6 +183,7 @@ BOOST_AUTO_TEST_CASE(existing_data_reindex)
|
||||
|
||||
// Call the destructor to free leveldb LOCK
|
||||
delete dbw;
|
||||
dbw = nullptr;
|
||||
|
||||
// Simulate a -reindex by wiping the existing data store
|
||||
CDBWrapper odbw(ph, (1 << 10), false, true, true);
|
||||
|
Loading…
Reference in New Issue
Block a user