Exemple #1
0
/* Called after a peer disconnects */
void mf_peer_context_free(freerdp_peer* client, mfPeerContext* context)
{
	if (context)
	{
		mf_info_peer_unregister(context->info, context);
		
		dispatch_suspend(info_timer);
		
		stream_free(context->s);
		
		rfx_context_free(context->rfx_context);
		//nsc_context_free(context->nsc_context);
		
#ifdef CHANNEL_AUDIN_SERVER
		if (context->audin)
			audin_server_context_free(context->audin);
#endif
		
		//#ifdef CHANNEL_RDPSND_SERVER
		mf_peer_rdpsnd_stop();
		if (context->rdpsnd)
			rdpsnd_server_context_free(context->rdpsnd);
		//#endif
		
		//#ifdef WITH_SERVER_CHANNELS
		WTSDestroyVirtualChannelManager(context->vcm);
		//#endif
	}
}
Exemple #2
0
void test_peer_context_free(freerdp_peer* client, testPeerContext* context)
{
	if (context)
	{
		if (context->debug_channel_thread)
		{
			freerdp_thread_stop(context->debug_channel_thread);
			freerdp_thread_free(context->debug_channel_thread);
		}

		stream_free(context->s);
		free(context->icon_data);
		free(context->bg_data);

		rfx_context_free(context->rfx_context);
		nsc_context_free(context->nsc_context);

		if (context->debug_channel)
			WTSVirtualChannelClose(context->debug_channel);

		if (context->audin)
			audin_server_context_free(context->audin);

		if (context->rdpsnd)
			rdpsnd_server_context_free(context->rdpsnd);

		WTSDestroyVirtualChannelManager(context->vcm);
	}
}
Exemple #3
0
void test_peer_context_free(freerdp_peer* client, testPeerContext* context)
{
	if (context)
	{
		if (context->debug_channel_thread)
		{
			SetEvent(context->stopEvent);
			WaitForSingleObject(context->debug_channel_thread, INFINITE);
			CloseHandle(context->debug_channel_thread);
		}

		Stream_Free(context->s, TRUE);
		free(context->icon_data);
		free(context->bg_data);

		rfx_context_free(context->rfx_context);
		nsc_context_free(context->nsc_context);

		if (context->debug_channel)
			WTSVirtualChannelClose(context->debug_channel);

		if (context->audin)
			audin_server_context_free(context->audin);

		if (context->rdpsnd)
			rdpsnd_server_context_free(context->rdpsnd);

		WTSDestroyVirtualChannelManager(context->vcm);
	}
}
Exemple #4
0
void wf_peer_context_free(freerdp_peer* client, wfPeerContext* context)
{
	wf_info_peer_unregister(context->info, context);

	if (context->rdpsnd)
	{
		wf_rdpsnd_lock();
		context->info->snd_stop = TRUE;
		rdpsnd_server_context_free(context->rdpsnd);
		wf_rdpsnd_unlock();
	}

	WTSDestroyVirtualChannelManager(context->vcm);
}
Exemple #5
0
void mf_peer_context_free(freerdp_peer* client, mfPeerContext* context)
{
	if (context)
	{
		stream_free(context->s);

		rfx_context_free(context->rfx_context);
		nsc_context_free(context->nsc_context);

		if (context->audin)
			audin_server_context_free(context->audin);

		if (context->rdpsnd)
			rdpsnd_server_context_free(context->rdpsnd);

		WTSDestroyVirtualChannelManager(context->vcm);
	}
}