Skip to content

ssl session cache: remember lock state locally - #23091

Closed
icing wants to merge 1 commit into
curl:masterfrom
icing:ssls-lock-state
Closed

icing wants to merge 1 commit into
curl:masterfrom
icing:ssls-lock-state

Conversation

@icing

@icing icing commented Sep 25, 2026

Copy link
Copy Markdown
Contributor

Remember the locking state locally on import so that there is no confusion with another thread having locked the cache in the meantime.

reported-by: Joshua Rogers

Remember the locking state locally on import so that there
is no confusion with another thread having locked the cache
in the meantime.

reported-by: Joshua Rogers

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Copilot review overview

🟢 Approval recommended

No unresolved review issues were identified.

Review effort: Lite
Findings: None

What changed in this PR

Updates SSL session-cache import cleanup to track lock ownership locally and avoid incorrect unlocks during concurrent access.

Changes:

  • Records lock acquisition with have_lock.
  • Unlocks only when this import call acquired the lock.
File Description
lib/​vtls/​vtls_scache.c Makes session-import lock cleanup ownership-aware.

💡 Add a code-review agent skill or configure MCP servers for context-aware, tailored reviews. Learn more in the docs.

@bagder bagder closed this in c28aeff Sep 25, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

Development

Successfully merging this pull request may close these issues.

2 participants