| 457 | } |
| 458 | |
| 459 | bool LegacyScriptPubKeyMan::CanGetAddresses(bool internal) const |
| 460 | { |
| 461 | LOCK(cs_KeyStore); |
| 462 | // Check if the keypool has keys |
| 463 | bool keypool_has_keys; |
| 464 | if (internal && m_storage.CanSupportFeature(FEATURE_HD_SPLIT)) { |
| 465 | keypool_has_keys = setInternalKeyPool.size() > 0; |
| 466 | } else { |
| 467 | keypool_has_keys = KeypoolCountExternalKeys() > 0; |
| 468 | } |
| 469 | // If the keypool doesn't have keys, check if we can generate them |
| 470 | if (!keypool_has_keys) { |
| 471 | return CanGenerateKeys(); |
| 472 | } |
| 473 | return keypool_has_keys; |
| 474 | } |
| 475 | |
| 476 | bool LegacyScriptPubKeyMan::Upgrade(int prev_version, int new_version, bilingual_str& error) |
| 477 | { |
nothing calls this directly
no test coverage detected