UsbDk: CWdmList::ForEach() fix recursive lock acquisition
Signed-off-by: Dmitry Fleytman <dfleytma@redhat.com>
This commit is contained in:
parent
12ef2e4ec9
commit
de546ef4ff
1 changed files with 8 additions and 3 deletions
|
|
@ -96,8 +96,7 @@ public:
|
|||
TEntryType *Pop()
|
||||
{
|
||||
CLockedContext<TAccessStrategy> LockedContext(*this);
|
||||
CounterDecrement();
|
||||
return TEntryType::GetByListEntry(RemoveHeadList(&m_List));
|
||||
return Pop_LockLess();
|
||||
}
|
||||
|
||||
ULONG Push(TEntryType *Entry)
|
||||
|
|
@ -129,7 +128,7 @@ public:
|
|||
CLockedContext<TAccessStrategy> LockedContext(*this);
|
||||
while (!IsListEmpty(&m_List))
|
||||
{
|
||||
Functor(Pop());
|
||||
Functor(Pop_LockLess());
|
||||
}
|
||||
}
|
||||
|
||||
|
|
@ -166,6 +165,12 @@ private:
|
|||
}
|
||||
}
|
||||
|
||||
TEntryType *Pop_LockLess()
|
||||
{
|
||||
CounterDecrement();
|
||||
return TEntryType::GetByListEntry(RemoveHeadList(&m_List));
|
||||
}
|
||||
|
||||
LIST_ENTRY m_List;
|
||||
ULONG m_NumEntries = 0;
|
||||
};
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue