| 220 | } |
| 221 | |
| 222 | std::vector<CAddress> ReadAnchors(const fs::path& anchors_db_path) |
| 223 | { |
| 224 | std::vector<CAddress> anchors; |
| 225 | try { |
| 226 | DeserializeFileDB(anchors_db_path, anchors, CLIENT_VERSION | ADDRV2_FORMAT); |
| 227 | LogPrintf("Loaded %i addresses from %s\n", anchors.size(), fs::quoted(fs::PathToString(anchors_db_path.filename()))); |
| 228 | } catch (const std::exception&) { |
| 229 | anchors.clear(); |
| 230 | } |
| 231 | |
| 232 | fs::remove(anchors_db_path); |
| 233 | return anchors; |
| 234 | } |
no test coverage detected