diff options
author | Jonas Schnelli <dev@jonasschnelli.ch> | 2017-06-23 09:33:31 +0200 |
---|---|---|
committer | Jonas Schnelli <dev@jonasschnelli.ch> | 2017-06-29 17:48:11 +0200 |
commit | ae09d4583b26251e67fa48216ebafb6bcdf2472b (patch) | |
tree | e21d6a89dee9ed86302240201eec4a1e41ffda8d /src/txdb.cpp | |
parent | 00cb69bc8655b1c17064a7e42453fd049e555076 (diff) |
Allow to shut down during txdb upgrade
Diffstat (limited to 'src/txdb.cpp')
-rw-r--r-- | src/txdb.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/src/txdb.cpp b/src/txdb.cpp index d24162ba2d..3e05683d1e 100644 --- a/src/txdb.cpp +++ b/src/txdb.cpp @@ -371,6 +371,9 @@ bool CCoinsViewDB::Upgrade() { CDBBatch batch(db); while (pcursor->Valid()) { boost::this_thread::interruption_point(); + if (ShutdownRequested()) { + break; + } std::pair<unsigned char, uint256> key; if (pcursor->GetKey(key) && key.first == DB_COINS) { CCoins old_coins; |