summaryrefslogtreecommitdiffstats
path: root/src/control/Garages.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'src/control/Garages.cpp')
-rw-r--r--src/control/Garages.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/control/Garages.cpp b/src/control/Garages.cpp
index 91971ae7..245e961d 100644
--- a/src/control/Garages.cpp
+++ b/src/control/Garages.cpp
@@ -2306,6 +2306,9 @@ void CGarages::Save(uint8 * buf, uint32 * size)
#else
* size = 5484;
#endif
+#if !defined THIS_IS_STUPID && !defined FIX_GARAGE_SIZE && defined COMPATIBLE_SAVES
+ memset(buf + 5240, 0, *size - 5240); // garbage data is written otherwise
+#endif
CloseHideOutGaragesBeforeSave();
WriteSaveBuf(buf, NumGarages);
WriteSaveBuf(buf, (uint32)BombsAreFree);