When the wallet is rescanned at startup in `bitcoind`, there seems to be no way to interrupt that in a clean way (other than forcefully killing the process).
{
    LOCK(cs_wallets);
    return !vpwallets.empty();
}
std::vector<CWallet*> GetWallets()
{
    LOCK(cs_wallets);
    return vpwallets;
}
CWallet* GetWallet(const std::string& name)
{
    LOCK(cs_wallets);
    for (CWallet* wallet : vpwallets) {
        if (wallet->GetName() == name) return wallet;
    }
    return nullptr;
}
const uint32_t BIP32_HARDENED_KEY_LIMIT = 0x80000000;
const uint256 CMerkleTx::ABANDON_HASH(uint256S("0000000000000000000000000000000000000000000000000000000000000001"));
/** @defgroup mapWallet
 *
 * @{
 */
std::string COutput::ToString() const
{
    return strprintf("COutput(%s, %d, %d) [%s]", tx->GetHash().ToString(), i, nDepth, FormatMoney(tx->tx->vout[i].nValue));
}
class CAffectedKeysVisitor : public boost::static_visitor<void> {