[Scummvm-tracker] [ScummVM :: Bugs] #13432: GUI: Options dialog complains about non-existing saves in autosave slot

ScummVM :: Bugs trac at scummvm.org
Wed Aug 3 04:00:16 UTC 2022


#13432: GUI: Options dialog complains about non-existing saves in autosave slot
-------------------------+--------------------------
Reporter:  eriktorbjorn  |       Owner:  (none)
    Type:  defect        |      Status:  new
Priority:  normal        |   Component:  Common
 Version:                |  Resolution:
Keywords:                |        Game:  Future Wars
-------------------------+--------------------------
Comment (by macca8):

 A word of caution.

 As it stands, it may be unsafe to reinstate the isAutosave() function as a
 supplementary test for an existing save in the Autosave slot, without
 causing an autosave to automatically overwrite any non-autosave saved game
 which may be occupying the slot.

 This is due to a change introduced by PR 3261, which initializes the
 _saveType value based on the slot type (the Autosave slot or a regular
 slot - refer
 engines/savestate.cpp/initSaveType()[https://github.com/scummvm/scummvm/pull/3261/commits/60e0a6db4002dd77a11f3e27d88d29ab5d193bd7
 60e0a6db]), without any regard to the type of save which may be occupying
 the slot (the primary function of the _saveType property).

 Currently, this value is only being used to determine if the Autosave slot
 is empty (isAutosave() replaces the "slot == autosave slot" test or
 equivalent), in which case a dummy autosave is created if required.
 Fortunately, only a minimal number of engines were directly affected by
 this change (Cine/, SCI/, engines/- metaengine.cpp)

 For isAutosave() to be used safely in its proper and intended context, I'd
 recommend that the _saveType initialization in initSaveType() be reverted
 (and appropriate adjustments made to the affected changes in commit
 60e0a6db), and initSaveType() be given a more appropriate name to reflect
 its primary function of initializing the writeProtected & Deletable flags.
-- 
Ticket URL: <https://bugs.scummvm.org/ticket/13432#comment:8>
ScummVM :: Bugs <https://bugs.scummvm.org>
ScummVM


More information about the Scummvm-tracker mailing list