Skip to content

Commit

Permalink
Browse files Browse the repository at this point in the history
Fixed double free
  • Loading branch information
akallabeth committed Jun 22, 2020
1 parent 36478d3 commit 6d86e20
Showing 1 changed file with 6 additions and 1 deletion.
7 changes: 6 additions & 1 deletion server/shadow/shadow_server.c
Expand Up @@ -586,14 +586,19 @@ int shadow_server_start(rdpShadowServer* server)
char** list = CommandLineParseCommaSeparatedValuesEx(NULL, server->ipcSocket, &count);
if (!list || (count <= 1))
{
free(list);
if (server->ipcSocket == NULL)
{
if (!open_port(server, NULL))
{
free(list);
return -1;
}
}
else
{
free(list);
return -1;
}
}

for (x = 1; x < count; x++)
Expand Down

0 comments on commit 6d86e20

Please sign in to comment.