| 51 | } |
| 52 | |
| 53 | void Unregister(CValidationInterface* callbacks) |
| 54 | { |
| 55 | LOCK(m_mutex); |
| 56 | auto it = m_map.find(callbacks); |
| 57 | if (it != m_map.end()) { |
| 58 | if (!--it->second->count) m_list.erase(it->second); |
| 59 | m_map.erase(it); |
| 60 | } |
| 61 | } |
| 62 | |
| 63 | //! Clear unregisters every previously registered callback, erasing every |
| 64 | //! map entry. After this call, the list may still contain callbacks that |
no test coverage detected