Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix list segfault #41

Open
wants to merge 2 commits into
base: master
Choose a base branch
from
Open

Fix list segfault #41

wants to merge 2 commits into from

Conversation

bertm
Copy link

@bertm bertm commented Sep 3, 2016

Entries were memset() to zero to erase them on eventUpdate,
unintentionally erasing the list member and corrupting the list they
are contained in. This resets the list member to its original value
after all members have been zeroed.

This fixes a null dereference in event_delete, that occurs when the entry after or before the corrupted entry is deleted. There, list_del would dereference the next pointer of the previous entry (and vice-versa), dereferencing a zeroed value.

This issue caused pidvbip to crash at least once per day for me, I have not experienced any such crash with this patch applied in some limited testing.

Entries were memset() to zero to erase them on eventUpdate,
unintentionally erasing the list member and corrupting the list they
are contained in. This resets the list member to its original value
after all members have been zeroed.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant