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

Don't leak on panic in extend #137

Merged
merged 1 commit into from Jan 4, 2019
Merged

Don't leak on panic in extend #137

merged 1 commit into from Jan 4, 2019

Commits on Jan 4, 2019

  1. Don't leak on panic in extend

    This ensures that the length of the SmallVec is updated even if the
    iterator panics in `next`.
    
    This uses `SetLenOnDrop` rather than setting the length inside the loop,
    because otherwise this suffers from the same optimization issue as
    rust-lang/rust#36355.
    
    Fixes servo#136.
    mbrubeck committed Jan 4, 2019
    Copy the full SHA
    a9b8635 View commit details
    Browse the repository at this point in the history