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: empty check and iterator validation in ContainerIterator::advance() #2894

Closed
wants to merge 1 commit into from

Commits on Sep 16, 2024

  1. fix: add empty check and iterator validation in ContainerIterator::ad…

    …vance()
    
    Description:
    This PR adds an !over.empty() check in ContainerIterator::advance() to ensure the iterator does not access an empty queue or go out of bounds during container iteration.
    
    Key Changes:
    
    Added validation to prevent accessing over.front() when the over queue is empty.
    Ensured the iterator cur is correctly repositioned to the next container, preventing out-of-bounds access to itemlist.
    This improves the stability and prevents potential crashes during container iteration.
    dudantas committed Sep 16, 2024
    Configuration menu
    Copy the full SHA
    61b5701 View commit details
    Browse the repository at this point in the history