Skip to content

Fix manual checkpoint in exclusive locking mode.#319

Merged
rhashimoto merged 1 commit into
masterfrom
fix-manual-checkpoint
Apr 16, 2026
Merged

Fix manual checkpoint in exclusive locking mode.#319
rhashimoto merged 1 commit into
masterfrom
fix-manual-checkpoint

Conversation

@rhashimoto
Copy link
Copy Markdown
Owner

Fix #318

Copy link
Copy Markdown
Contributor

@gemini-code-assist gemini-code-assist Bot left a comment

Choose a reason for hiding this comment

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

Code Review

This pull request modifies the lock acquisition logic in the #pendingCheckpoint method of OPFSWriteAheadVFS.js to conditionally skip acquiring an exclusive write lock. A review comment identifies a concurrency risk where the current check for SQLITE_LOCK_NONE is too broad, potentially allowing checkpoints to proceed without a write lock in normal locking modes. It is suggested to refine the condition to account for the connection's locking mode.

Comment thread src/examples/OPFSWriteAheadVFS.js
@rhashimoto rhashimoto merged commit 9163574 into master Apr 16, 2026
1 check passed
@rhashimoto rhashimoto deleted the fix-manual-checkpoint branch April 16, 2026 16:52
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

manual checkpoint with OPFSWriteAheadVFS fails in exclusive locking mode

2 participants