malloc to calloc
This commit is contained in:
@@ -166,8 +166,7 @@ ps1snd_get_buffer(int32_t *buffer, int len, void *priv)
|
||||
static void *
|
||||
ps1snd_init(UNUSED(const device_t *info))
|
||||
{
|
||||
ps1snd_t *ps1snd = malloc(sizeof(ps1snd_t));
|
||||
memset(ps1snd, 0x00, sizeof(ps1snd_t));
|
||||
ps1snd_t *ps1snd = calloc(1, sizeof(ps1snd_t));
|
||||
|
||||
sn76489_init(&ps1snd->sn76489, 0x0205, 0x0001, SN76496, 4000000);
|
||||
|
||||
|
||||
Reference in New Issue
Block a user