Skip to content

fix: parallelize and bound OS shutdown disk saves#61

Merged
coldhighsun merged 1 commit into
mainfrom
fix/session-ending-save
Jul 17, 2026
Merged

fix: parallelize and bound OS shutdown disk saves#61
coldhighsun merged 1 commit into
mainfrom
fix/session-ending-save

Conversation

@coldhighsun

Copy link
Copy Markdown
Owner

Save all mounted disks concurrently on SystemEvents.SessionEnding instead of sequentially, and skip disks with no unsaved changes, so multi-disk saves are more likely to complete within the Windows shutdown time budget. Bound the wait with a timeout so a single stuck save can't block the callback indefinitely, and extract the shared dirty/path-changed skip condition into RamDisk.NeedsSave() to avoid duplicating it across SaveToImageSafe, TryAutoSave, and Dispose.

Save all mounted disks concurrently on SystemEvents.SessionEnding
instead of sequentially, and skip disks with no unsaved changes, so
multi-disk saves are more likely to complete within the Windows
shutdown time budget. Bound the wait with a timeout so a single stuck
save can't block the callback indefinitely, and extract the shared
dirty/path-changed skip condition into RamDisk.NeedsSave() to avoid
duplicating it across SaveToImageSafe, TryAutoSave, and Dispose.
@coldhighsun
coldhighsun merged commit f52c916 into main Jul 17, 2026
3 checks passed
@coldhighsun
coldhighsun deleted the fix/session-ending-save branch July 17, 2026 09:38
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.

1 participant