server/shadow: close the thread handle so that it is detached because no one is going to join it. Therefore the thread would release its resources automatically when exit

This commit is contained in:
zihao.jiang 2017-04-11 02:25:36 +08:00
parent 215fbe8446
commit 74db87a473

View File

@ -1747,6 +1747,12 @@ BOOL shadow_client_accepted(freerdp_listener* listener, freerdp_peer* peer)
freerdp_peer_context_free(peer);
return FALSE;
}
else
{
/* Close the thread handle to make it detached. */
CloseHandle(client->thread);
client->thread = NULL;
}
return TRUE;
}