Update lru to 0.18.2 - #5
Open
nabbisen wants to merge 1 commit into
Open
Conversation
Author
|
For context: upstream The two have diverged (wgpu 29 / etagere 0.2 here vs wgpu 30 / etagere 0.3 upstream), so neither PR substitutes for the other — this one is what reaches |
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
lru 0.16.4carries RUSTSEC-2026-0253 — an unsoundness inLruCache::pop(), where the node is freed and the key dropped before it is detached from the intrusive list, so a panic in the key'sDropcan leave neighbouring nodes pointing at freed memory. Fixed inlru 0.18.2by detaching first.cryoglyph does not appear to be affected, for two independent reasons:
LruCache<CacheKey, GlyphDetails, Hasher>, andcosmic_text::CacheKeyisCopy— so it cannot implementDropat all, and the key'sdrop_in_placeis a no-op that cannot panic.pop_lru(), not the affectedpop().So this is dependency hygiene, not a bug fix.
It matters downstream because every consumer of
icedinherits the advisory throughiced_wgpu → cryoglyph, and projects runningcargo audit --deny warningsin CI go red until they add an exception.The requirement is
"0.18.2"rather than"0.18"deliberately:lru 0.18.0and0.18.1are published and are not patched, so^0.18could still resolve to a vulnerable version.No source changes were needed — the five
lruAPIs used here (unbounded_with_hasher,get,get_or_insert,peek_lru,pop_lru) are unchanged in 0.18.2. Verified withcargo checkagainstmasterat f4e7e4e; the resolved lockfile entry islru 0.18.2.Happy to close this if you would rather handle it another way.