Files
skylar taylor-barrick 5bc5478499 fix(engine): keep earlier saves when undo crosses a security change (#3276)
From review. When undo restores security from before the last save, the
save now goes onto the newest file of this session that has the
snapshot's security and continues its source, not only the source
itself. An edit saved before the security change keeps its revision;
only revisions in the other security, all undone, are dropped.

save_bytes compares the saved file's security, recorded at mark_saved
as a SecurityIdentity (dictionary and, below revision 5, first /ID),
before opening anything. The chosen file is opened with the snapshot's
key, so a password that no longer opens the last save can't fail it.
One early return covers a snapshot that is its target unchanged.

overlay_changes_from keeps reading this file under its own /Encrypt
number and records the snapshot's only for writing, and refuses a
document with a pending security change.
2026-10-20 01:09:57 +02:00
..
2026-10-16 14:11:53 +00:00