mirror of
https://github.com/morgan9e/FreeRDP
synced 2026-04-15 00:44:19 +09:00
Exposed WTSVirtualChannelManagerOpen
This commit is contained in:
@@ -63,6 +63,7 @@ extern "C"
|
||||
"Use WTSVirtualChannelManagerGetEventHandle",
|
||||
void WTSVirtualChannelManagerGetFileDescriptor(HANDLE hServer, void** fds, int* fds_count));
|
||||
#endif
|
||||
FREERDP_API BOOL WTSVirtualChannelManagerOpen(HANDLE hServer);
|
||||
FREERDP_API BOOL WTSVirtualChannelManagerCheckFileDescriptor(HANDLE hServer);
|
||||
FREERDP_API BOOL WTSVirtualChannelManagerCheckFileDescriptorEx(HANDLE hServer, BOOL autoOpen);
|
||||
FREERDP_API HANDLE WTSVirtualChannelManagerGetEventHandle(HANDLE hServer);
|
||||
|
||||
@@ -529,14 +529,18 @@ void WTSVirtualChannelManagerGetFileDescriptor(HANDLE hServer, void** fds, int*
|
||||
}
|
||||
#endif
|
||||
|
||||
static BOOL WTSVirtualChannelManagerOpen(WTSVirtualChannelManager* vcm)
|
||||
BOOL WTSVirtualChannelManagerOpen(HANDLE hServer)
|
||||
{
|
||||
WTSVirtualChannelManager* vcm = (WTSVirtualChannelManager*)hServer;
|
||||
const freerdp_peer* client;
|
||||
|
||||
if (!vcm)
|
||||
return FALSE;
|
||||
|
||||
WINPR_ASSERT(vcm->client);
|
||||
client = vcm->client;
|
||||
|
||||
if ((vcm->drdynvc_state == DRDYNVC_STATE_NONE) && vcm->client->activated)
|
||||
if (vcm->drdynvc_state == DRDYNVC_STATE_NONE)
|
||||
{
|
||||
rdpPeerChannel* channel;
|
||||
UINT32 dynvc_caps;
|
||||
@@ -573,7 +577,7 @@ BOOL WTSVirtualChannelManagerCheckFileDescriptorEx(HANDLE hServer, BOOL autoOpen
|
||||
|
||||
if (autoOpen)
|
||||
{
|
||||
if (!WTSVirtualChannelManagerOpen(vcm))
|
||||
if (!WTSVirtualChannelManagerOpen(hServer))
|
||||
return FALSE;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user