mirror of
https://github.com/morgan9e/FreeRDP
synced 2026-04-15 00:44:19 +09:00
[winpr,wtsapi] improve API usage
* Mark WTSVirtualChannelOpen and WTSVirtualChannelOpenEx with WINPR_ATTR_MALLOC to enforce compiler checks for resource cleanup * Fix unused result warnings, use the result or cast to (void) where not requierd
This commit is contained in:
@@ -474,7 +474,7 @@ static UINT disp_server_open(DispServerContext* context)
|
||||
|
||||
return CHANNEL_RC_OK;
|
||||
out_close:
|
||||
WTSVirtualChannelClose(priv->disp_channel);
|
||||
(void)WTSVirtualChannelClose(priv->disp_channel);
|
||||
priv->disp_channel = NULL;
|
||||
priv->channelEvent = NULL;
|
||||
return rc;
|
||||
@@ -567,7 +567,7 @@ static UINT disp_server_close(DispServerContext* context)
|
||||
|
||||
if (priv->disp_channel)
|
||||
{
|
||||
WTSVirtualChannelClose(priv->disp_channel);
|
||||
(void)WTSVirtualChannelClose(priv->disp_channel);
|
||||
priv->disp_channel = NULL;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user