Skip to content

Commit 9d4eb9a

Browse files
committed
Do diskspace check before import thread is started
1 parent aa59f2e commit 9d4eb9a

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

src/init.cpp

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -1418,6 +1418,9 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler)
14181418

14191419
// ********************************************************* Step 10: import blocks
14201420

1421+
if (!CheckDiskSpace())
1422+
return false;
1423+
14211424
// Either install a handler to notify us when genesis activates, or set fHaveGenesis directly.
14221425
// No locking, as this happens before any background thread is started.
14231426
if (chainActive.Tip() == NULL) {
@@ -1449,9 +1452,6 @@ bool AppInit2(boost::thread_group& threadGroup, CScheduler& scheduler)
14491452

14501453
// ********************************************************* Step 11: start node
14511454

1452-
if (!CheckDiskSpace())
1453-
return false;
1454-
14551455
if (!strErrors.str().empty())
14561456
return InitError(strErrors.str());
14571457

0 commit comments

Comments
 (0)