File tree Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Expand file tree Collapse file tree 2 files changed +3
-2
lines changed Original file line number Diff line number Diff line change @@ -179,10 +179,11 @@ void BanMan::GetBanned(banmap_t& banmap)
179179
180180void BanMan::SweepBanned ()
181181{
182+ AssertLockHeld (m_cs_banned);
183+
182184 int64_t now = GetTime ();
183185 bool notify_ui = false ;
184186 {
185- LOCK (m_cs_banned);
186187 banmap_t ::iterator it = m_banned.begin ();
187188 while (it != m_banned.end ()) {
188189 CSubNet sub_net = (*it).first ;
Original file line number Diff line number Diff line change @@ -85,7 +85,7 @@ class BanMan
8585 // !set the "dirty" flag for the banlist
8686 void SetBannedSetDirty (bool dirty = true );
8787 // !clean unused entries (if bantime has expired)
88- void SweepBanned ();
88+ void SweepBanned () EXCLUSIVE_LOCKS_REQUIRED(m_cs_banned) ;
8989
9090 RecursiveMutex m_cs_banned;
9191 banmap_t m_banned GUARDED_BY (m_cs_banned);
You can’t perform that action at this time.
0 commit comments