mirror of
https://github.com/libretro/RetroArch
synced 2025-01-30 21:32:45 +00:00
(Switch) Replace malloc() with calloc() in switch_gfx.c
This commit is contained in:
parent
93523782e5
commit
bb1fdad0d9
@ -63,7 +63,7 @@ static void *switch_init(const video_info_t *video,
|
|||||||
const input_driver_t **input, void **input_data)
|
const input_driver_t **input, void **input_data)
|
||||||
{
|
{
|
||||||
unsigned x, y;
|
unsigned x, y;
|
||||||
switch_video_t *sw = malloc(sizeof(*sw));
|
switch_video_t *sw = (switch_video_t*)calloc(1, sizeof(*sw));
|
||||||
if (!sw)
|
if (!sw)
|
||||||
return NULL;
|
return NULL;
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user