Skip to content

Conversation

reusee
Copy link
Contributor

@reusee reusee commented Jul 18, 2025

What type of PR is this?

  • API-change
  • BUG
  • Improvement
  • Documentation
  • Feature
  • Test and CI
  • Code Refactoring

Which issue(s) this PR fixes:

issue #22195

What this PR does / why we need it:

Fix potential double free in the fifocache.

The postEvict callback may be incorrectly called twice in this situation:

  1. Item is deleted by calling Delete explicitly;
  2. The item is evicted from the queue.

Fixed by checking item existence in the values map before calling postEvict.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
kind/bug Something isn't working size/S Denotes a PR that changes [10,99] lines
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants