Skip to content

Commit 2a7aefa

Browse files
author
Federico Berti
committed
h
1 parent b6afa29 commit 2a7aefa

File tree

2 files changed

+9
-5
lines changed

2 files changed

+9
-5
lines changed

HISTORY.md

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,8 @@
1+
## 23.0506
2+
helios: add Sega 32x emulation by merging the helios32x project: https://github.com/fedex81/helios32x
3+
md: improve rom header parsing
4+
md: improve support for roms > 4Mbit with sram
5+
16
## 22.1205
27
68k: support cycle table from genPlusGx
38
68k: fix *bcd, link corner cases

src/main/java/s32x/savestate/Gs32xStateHandler.java

Lines changed: 4 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -15,10 +15,7 @@
1515
import java.io.Serial;
1616
import java.io.Serializable;
1717
import java.nio.ByteBuffer;
18-
import java.util.LinkedHashMap;
19-
import java.util.Map;
20-
import java.util.Set;
21-
import java.util.WeakHashMap;
18+
import java.util.*;
2219

2320
import static omegadrive.savestate.StateUtil.storeSerializedData;
2421

@@ -39,6 +36,8 @@ public class Gs32xStateHandler extends GshStateHandler {
3936
private static final Map<String, Device> s32xDeviceSet = new WeakHashMap<>();
4037
private static final Sh2ContextWrap wrap = new Sh2ContextWrap();
4138

39+
private ByteBuffer b = ByteBuffer.allocate(FILE_SIZE << 4);
40+
4241
static class S32xContainer implements Serializable {
4342
@Serial
4443
private static final long serialVersionUID = 5388883919206790206L;
@@ -112,7 +111,7 @@ public static void addDevice(Device d) {
112111
@Override
113112
public void processState() {
114113
super.processState(); //do MD stuff
115-
ByteBuffer b = ByteBuffer.allocate(FILE_SIZE << 4);
114+
Arrays.fill(b.array(), (byte) 0);
116115
assert !s32xDeviceSet.isEmpty();
117116
if (type == Type.SAVE) {
118117
S32xContainer container = new S32xContainer();

0 commit comments

Comments
 (0)