Changes between Version 2 and Version 3 of Ticket #13842


Ignore:
Timestamp:
10/05/22 04:37:17 (19 months ago)
Author:
macca8
Comment:

Since there's been no response, I'm changing the component to something more generic, in the hope of stimulating some interest, and avoiding this issue finding its way into the 2.6.1 release (the same applies to #13841).

Not sure which is the correct component here. It's really a global issue affecting all engines, but there's no general "Engines" component listed (perhaps that should be added to the list, similar to Ports?), so I've settled on Other, rather than Common (which was used with 9b05c206, which originally exposed this issue).

Legend:

Unmodified
Added
Removed
Modified
  • Ticket #13842

    • Property Component Common--Other--
    • Property Summary ENGINES: Fix proper detection of autosaves by isAutosave() function.ENGINES: AUTOSAVE: Fix proper detection of autosaves by isAutosave() function.
  • Ticket #13842 – Description

    v2 v3  
    1818In practice, because each test is based on a different aspect of the save process, each false positive is offset by the other test correctly identifying the autosave file. Examples of these false positives, which were resolved by switching tests, can be found in #12363, #13432 & #13703.
    1919
    20 Since switching the autosave test back to isAutosave(), after using hasAutosaveName() exclusively ([https://github.com/scummvm/scummvm/commit/9b05c206993d3107f98ac5b437801e33ba3c79b7 9b05c206]), the bug in #12363 has been reinstated (applies to Myst III, and any game which offers write access in the autosave slot, and which also sets the _saveType value based on the autosave flag).
     20Since switching the autosave test back to isAutosave() ([https://github.com/scummvm/scummvm/commit/9b05c206993d3107f98ac5b437801e33ba3c79b7 9b05c206]), after using hasAutosaveName() exclusively, the bug in #12363 has been reinstated (applies to Myst III, and any game which offers write access in the autosave slot, and which also sets the _saveType value based on the autosave flag).
    2121
    2222The name and saveType tests are already quite comprehensive, and don’t need any further adjustment. What’s needed to properly detect the autosave file is a restructure of the isAutosave() function’s definition, to prioritise the name test (the primary test), and follow up with the saveType test (the supplementary test) only if that test fails.. a genuine autosave file need only pass one of the tests, whereas a regular save will fail both.