Channels with a context must free it themselves.
This commit is contained in:
parent
11fa9f6753
commit
523a881663
@ -1182,6 +1182,7 @@ static UINT cliprdr_virtual_channel_event_disconnected(cliprdrPlugin* cliprdr)
|
||||
static UINT cliprdr_virtual_channel_event_terminated(cliprdrPlugin* cliprdr)
|
||||
{
|
||||
cliprdr->InitHandle = 0;
|
||||
free(cliprdr->context);
|
||||
free(cliprdr);
|
||||
return CHANNEL_RC_OK;
|
||||
}
|
||||
|
@ -1436,6 +1436,7 @@ static UINT drdynvc_virtual_channel_event_terminated(drdynvcPlugin* drdynvc)
|
||||
return CHANNEL_RC_BAD_CHANNEL_HANDLE;
|
||||
|
||||
drdynvc->InitHandle = 0;
|
||||
free(drdynvc->context);
|
||||
free(drdynvc);
|
||||
return CHANNEL_RC_OK;
|
||||
}
|
||||
|
@ -1148,6 +1148,7 @@ static UINT encomsp_virtual_channel_event_disconnected(encomspPlugin* encomsp)
|
||||
static UINT encomsp_virtual_channel_event_terminated(encomspPlugin* encomsp)
|
||||
{
|
||||
encomsp->InitHandle = 0;
|
||||
free(encomsp->context);
|
||||
free(encomsp);
|
||||
return CHANNEL_RC_OK;
|
||||
}
|
||||
|
@ -738,6 +738,7 @@ static UINT rail_virtual_channel_event_disconnected(railPlugin* rail)
|
||||
static void rail_virtual_channel_event_terminated(railPlugin* rail)
|
||||
{
|
||||
rail->InitHandle = 0;
|
||||
free(rail->context);
|
||||
free(rail);
|
||||
}
|
||||
|
||||
|
@ -942,6 +942,7 @@ static UINT remdesk_virtual_channel_event_disconnected(remdeskPlugin* remdesk)
|
||||
static void remdesk_virtual_channel_event_terminated(remdeskPlugin* remdesk)
|
||||
{
|
||||
remdesk->InitHandle = 0;
|
||||
free(remdesk->context);
|
||||
free(remdesk);
|
||||
}
|
||||
|
||||
|
@ -663,12 +663,6 @@ void freerdp_channels_close(rdpChannels* channels, freerdp* instance)
|
||||
{
|
||||
pChannelOpenData = &channels->openDataList[index];
|
||||
|
||||
if (pChannelOpenData->pInterface)
|
||||
{
|
||||
free(pChannelOpenData->pInterface);
|
||||
pChannelOpenData->pInterface = NULL;
|
||||
}
|
||||
|
||||
freerdp_channel_remove_open_handle_data(&g_ChannelHandles, pChannelOpenData->OpenHandle);
|
||||
|
||||
if (channels->openHandles)
|
||||
|
Loading…
Reference in New Issue
Block a user