Walking a doubly circular linked list wrong
Opened this issue · 0 comments
BigJim commented
In ObCallbacks.c line #68 you have a while loop walking forward on a doubly circular linked list.
It's in error and it will cause an exception every time it's called, either when the list is empty or when advancing to the last (actually goes past) node; which is normally hidden by the __try/__except handler.
Should change the loop like this:
while ((POBJECT_CALLBACK_ENTRY) pCallbackEntry->CallbackList.Flink != Head)
{
... inner loop code..
pCallbackEntry = (POBJECT_CALLBACK_ENTRY) pCallbackEntry->CallbackList.Flink;
}