summaryrefslogtreecommitdiff
path: root/Source/Core
diff options
context:
space:
mode:
authorRachel Bryk <RachelBryk@gmail.com>2013-02-26 18:28:56 -0500
committerRachel Bryk <RachelBryk@gmail.com>2013-02-26 18:28:56 -0500
commit08fe3c213ad71e903fed83edfada5a79c75f11f9 (patch)
tree886413488b7046b9f6f047fc86c4126e9ca3c95a /Source/Core
parentdb838e759b8935e213fa225be88ac0bfc78c27f7 (diff)
Abort loading states from incompatible graphics backends.
Diffstat (limited to 'Source/Core')
-rw-r--r--Source/Core/Core/Src/State.cpp2
-rw-r--r--Source/Core/VideoCommon/Src/MainBase.cpp5
2 files changed, 6 insertions, 1 deletions
diff --git a/Source/Core/Core/Src/State.cpp b/Source/Core/Core/Src/State.cpp
index 0facf2f387..773d757337 100644
--- a/Source/Core/Core/Src/State.cpp
+++ b/Source/Core/Core/Src/State.cpp
@@ -71,7 +71,7 @@ static Common::Event g_compressAndDumpStateSyncEvent;
static std::thread g_save_thread;
// Don't forget to increase this after doing changes on the savestate system
-static const u32 STATE_VERSION = 14;
+static const u32 STATE_VERSION = 15;
struct StateHeader
{
diff --git a/Source/Core/VideoCommon/Src/MainBase.cpp b/Source/Core/VideoCommon/Src/MainBase.cpp
index 726ef71b38..a881bebfb2 100644
--- a/Source/Core/VideoCommon/Src/MainBase.cpp
+++ b/Source/Core/VideoCommon/Src/MainBase.cpp
@@ -186,6 +186,11 @@ void VideoBackendHardware::InitializeShared()
// Run from the CPU thread
void VideoBackendHardware::DoState(PointerWrap& p)
{
+ bool software = false;
+ p.Do(software);
+ if (p.GetMode() == PointerWrap::MODE_READ && software == true)
+ // change mode to abort load of incompatible save state.
+ p.SetMode(PointerWrap::MODE_VERIFY);
VideoCommon_DoState(p);
p.DoMarker("VideoCommon");