mirror of
https://github.com/libretro/RetroArch
synced 2025-01-30 12:32:52 +00:00
Prevent memcpy if data->data is NULL
This commit is contained in:
parent
8698525f86
commit
8ad2b5000f
@ -3332,9 +3332,12 @@ static void netplay_refresh_rooms_cb(void *task_data, void *user_data, const cha
|
||||
if (!data || err)
|
||||
goto finish;
|
||||
|
||||
memcpy(buf, data->data, data->len * sizeof(char));
|
||||
buf[data->len] = '\0';
|
||||
|
||||
if (data)
|
||||
{
|
||||
if (data->data)
|
||||
memcpy(buf, data->data, data->len * sizeof(char));
|
||||
buf[data->len] = '\0';
|
||||
}
|
||||
|
||||
finish:
|
||||
if (!err && !strstr(buf, file_path_str(FILE_PATH_NETPLAY_ROOM_LIST_URL)))
|
||||
|
Loading…
x
Reference in New Issue
Block a user