Fix a bug that could segfault with fast dis/reconnection.
This commit is contained in:
parent
c8ec048459
commit
ab669a2db8
|
@ -1300,7 +1300,8 @@ static bool netplay_get_cmd(netplay_t *netplay,
|
||||||
if (!(devices & (1<<device))) continue;
|
if (!(devices & (1<<device))) continue;
|
||||||
netplay_input_state_t istate = netplay_input_state_for(
|
netplay_input_state_t istate = netplay_input_state_for(
|
||||||
&dframe->real_input[device], client_num,
|
&dframe->real_input[device], client_num,
|
||||||
3 /* FIXME */, true, false);
|
3 /* FIXME */, false, false);
|
||||||
|
if (!istate) continue;
|
||||||
memset(istate->data, 0, istate->size*sizeof(uint32_t));
|
memset(istate->data, 0, istate->size*sizeof(uint32_t));
|
||||||
}
|
}
|
||||||
dframe->have_local = true;
|
dframe->have_local = true;
|
||||||
|
|
Loading…
Reference in New Issue