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)
179
179
180
180
void BanMan::SweepBanned ()
181
181
{
182
+ AssertLockHeld (m_cs_banned);
183
+
182
184
int64_t now = GetTime ();
183
185
bool notify_ui = false ;
184
186
{
185
- LOCK (m_cs_banned);
186
187
banmap_t ::iterator it = m_banned.begin ();
187
188
while (it != m_banned.end ()) {
188
189
CSubNet sub_net = (*it).first ;
Original file line number Diff line number Diff line change @@ -85,7 +85,7 @@ class BanMan
85
85
// !set the "dirty" flag for the banlist
86
86
void SetBannedSetDirty (bool dirty = true );
87
87
// !clean unused entries (if bantime has expired)
88
- void SweepBanned ();
88
+ void SweepBanned () EXCLUSIVE_LOCKS_REQUIRED(m_cs_banned) ;
89
89
90
90
RecursiveMutex m_cs_banned;
91
91
banmap_t m_banned GUARDED_BY (m_cs_banned);
You can’t perform that action at this time.
0 commit comments