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

Disallow null in QueueReader to handle concurrency correctly #2041

Merged
merged 2 commits into from
Jan 11, 2024

Conversation

MarcMil
Copy link
Contributor

@MarcMil MarcMil commented Jan 11, 2024

Before that, it could happen that the QueueReader's hasNext method is called, and then the corresponding element gets invalidated by another thread. In that case, the next method throw a NoSuchElement exce> Instead (and conforming to to the JavaDoc), we allow null to be returned in these cases. This means that ChunkedQueues may not contain actual nulls anymore.

Before that, it could happen that the QueueReader's hasNext method is called, and then the corresponding element gets invalidated by another thread. In that case, the next method throw a NoSuchElement exce>
Instead (and conforming to to the JavaDoc), we allow null to be returned in these cases.
This means that ChunkedQueues may not contain actual nulls anymore.
@StevenArzt StevenArzt merged commit 395b878 into soot-oss:develop Jan 11, 2024
5 checks passed
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.

2 participants