mirror of
https://github.com/holub/mame
synced 2025-04-27 18:53:05 +03:00
Fix for memsets in core (no whatsnew)
This commit is contained in:
parent
ff0d52a4f6
commit
5a59cde33d
@ -251,7 +251,7 @@ static CPU_INIT( esrip )
|
|||||||
esrip_state *cpustate = get_safe_token(device);
|
esrip_state *cpustate = get_safe_token(device);
|
||||||
esrip_config* _config = (esrip_config*)device->static_config();
|
esrip_config* _config = (esrip_config*)device->static_config();
|
||||||
|
|
||||||
memset(cpustate, 0, sizeof(cpustate));
|
memset(cpustate, 0, sizeof(esrip_state));
|
||||||
|
|
||||||
/* Register configuration structure callbacks */
|
/* Register configuration structure callbacks */
|
||||||
cpustate->fdt_r = _config->fdt_r;
|
cpustate->fdt_r = _config->fdt_r;
|
||||||
|
@ -331,7 +331,7 @@ static CPU_INIT( g65816 )
|
|||||||
{
|
{
|
||||||
g65816i_cpu_struct *cpustate = get_safe_token(device);
|
g65816i_cpu_struct *cpustate = get_safe_token(device);
|
||||||
|
|
||||||
memset(cpustate, 0, sizeof(cpustate));
|
memset(cpustate, 0, sizeof(g65816i_cpu_struct));
|
||||||
|
|
||||||
g65816_set_irq_callback(cpustate, irqcallback);
|
g65816_set_irq_callback(cpustate, irqcallback);
|
||||||
cpustate->device = device;
|
cpustate->device = device;
|
||||||
|
@ -891,7 +891,7 @@ static CPU_INIT( m37710 )
|
|||||||
m37710i_cpu_struct *cpustate = get_safe_token(device);
|
m37710i_cpu_struct *cpustate = get_safe_token(device);
|
||||||
int i;
|
int i;
|
||||||
|
|
||||||
memset(cpustate, 0, sizeof(cpustate));
|
memset(cpustate, 0, sizeof(m37710i_cpu_struct));
|
||||||
|
|
||||||
INT_ACK = irqcallback;
|
INT_ACK = irqcallback;
|
||||||
cpustate->device = device;
|
cpustate->device = device;
|
||||||
|
@ -343,7 +343,7 @@ static void nec_init(legacy_cpu_device *device, device_irq_callback irqcallback)
|
|||||||
Mod_RM.RM.b[i] = breg_name[i & 7];
|
Mod_RM.RM.b[i] = breg_name[i & 7];
|
||||||
}
|
}
|
||||||
|
|
||||||
memset(nec_state, 0, sizeof(nec_state));
|
memset(nec_state, 0, sizeof(nec_state_t));
|
||||||
|
|
||||||
device->save_item(NAME(nec_state->regs.w));
|
device->save_item(NAME(nec_state->regs.w));
|
||||||
device->save_item(NAME(nec_state->sregs));
|
device->save_item(NAME(nec_state->sregs));
|
||||||
|
@ -432,7 +432,7 @@ static void v25_init(legacy_cpu_device *device, device_irq_callback irqcallback)
|
|||||||
Mod_RM.RM.b[i] = breg_name[i & 7];
|
Mod_RM.RM.b[i] = breg_name[i & 7];
|
||||||
}
|
}
|
||||||
|
|
||||||
memset(nec_state, 0, sizeof(nec_state));
|
memset(nec_state, 0, sizeof(v25_state_t));
|
||||||
|
|
||||||
nec_state->config = config;
|
nec_state->config = config;
|
||||||
|
|
||||||
|
@ -129,7 +129,7 @@ MD5Final(md5byte digest[16], struct MD5Context *ctx)
|
|||||||
|
|
||||||
byteSwap(ctx->buf, 4);
|
byteSwap(ctx->buf, 4);
|
||||||
memcpy(digest, ctx->buf, 16);
|
memcpy(digest, ctx->buf, 16);
|
||||||
memset(ctx, 0, sizeof(ctx)); /* In case it's sensitive */
|
memset(ctx, 0, sizeof(MD5Context)); /* In case it's sensitive */
|
||||||
}
|
}
|
||||||
|
|
||||||
#ifndef ASM_MD5
|
#ifndef ASM_MD5
|
||||||
|
Loading…
Reference in New Issue
Block a user