summaryrefslogtreecommitdiffstatshomepage
path: root/src
diff options
context:
space:
mode:
author Phil Bennett <philipjbennett@users.noreply.github.com>2008-10-21 20:42:56 +0000
committer Phil Bennett <philipjbennett@users.noreply.github.com>2008-10-21 20:42:56 +0000
commit40520a87cd0e332b47ce71c444c40d355a10cc5e (patch)
tree568c1eea6f5223c17175ec3fe7da6a47bf9b1c37 /src
parent8b368475fad5349888ad410e5b570d319ef2b423 (diff)
Fix MT 02140: "cube quest crashes mame when saving state"
Diffstat (limited to 'src')
-rw-r--r--src/emu/cpu/cubeqcpu/cubeqcpu.c12
1 files changed, 6 insertions, 6 deletions
diff --git a/src/emu/cpu/cubeqcpu/cubeqcpu.c b/src/emu/cpu/cubeqcpu/cubeqcpu.c
index bc0b37246b6..dc05f34d476 100644
--- a/src/emu/cpu/cubeqcpu/cubeqcpu.c
+++ b/src/emu/cpu/cubeqcpu/cubeqcpu.c
@@ -341,13 +341,13 @@ static void cquestsnd_init(int index, int clock, const void *config, int (*irqca
memset(&cquestsnd, 0, sizeof(cquestsnd));
- cquestsnd_state_register(index, "cquestsnd");
-
cquestsnd.dac_w = _config->dac_w;
cquestsnd.sound_data = (UINT16*)memory_region(Machine, _config->sound_data_region);
/* Allocate RAM shared with 68000 */
cquestsnd.sram = malloc(4096);
+
+ cquestsnd_state_register(index, "cquestsnd");
}
@@ -407,11 +407,11 @@ static void cquestrot_init(int index, int clock, const void *_config, int (*irqc
{
memset(&cquestrot, 0, sizeof(cquestrot));
- cquestrot_state_register(index, "cquestrot");
-
/* Allocate RAM */
cquestrot.dram = malloc(16384 * sizeof(UINT16)); /* Shared with 68000 */
cquestrot.sram = malloc(2048 * sizeof(UINT16)); /* Private */
+
+ cquestrot_state_register(index, "cquestrot");
}
@@ -483,13 +483,13 @@ static void cquestlin_init(int index, int clock, const void *_config, int (*irqc
{
memset(&cquestlin, 0, sizeof(cquestlin));
- cquestlin_state_register(index, "cquestlin");
-
/* Allocate RAM */
cquestlin.sram = malloc(4096 * sizeof(UINT16)); /* Shared with rotate CPU */
cquestlin.ptr_ram = malloc(1024); /* Pointer RAM */
cquestlin.e_stack = malloc(32768 * sizeof(UINT32)); /* Stack DRAM: 32kx20 */
cquestlin.o_stack = malloc(32768 * sizeof(UINT32)); /* Stack DRAM: 32kx20 */
+
+ cquestlin_state_register(index, "cquestlin");
}