Merge pull request #14061 from Cthulhu-throwaway/netplay-buildfix

(Netplay) Buildfix for some "dumber" compilers
This commit is contained in:
LibretroAdmin 2022-06-18 16:32:13 +01:00 committed by GitHub
commit 852b3f2071
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -3380,7 +3380,7 @@ critical_failure:
static struct netplay_connection *allocate_connection(netplay_t *netplay)
{
size_t i;
struct netplay_connection *connection;
struct netplay_connection *connection = NULL;
/* Look for an existing non-used connection first. */
for (i = 0; i < netplay->connections_size; i++)
@ -3391,7 +3391,9 @@ static struct netplay_connection *allocate_connection(netplay_t *netplay)
break;
}
if (i < netplay->connections_size)
{
memset(connection, 0, sizeof(*connection));
}
else if (!netplay->connections_size)
{
netplay->connections =