Skip to content

Commit 600095a

Browse files
committed
Update for unification of monitor processing
Related to neutrinolabs/xrdp#1895
1 parent ad5f3c8 commit 600095a

File tree

1 file changed

+18
-0
lines changed

1 file changed

+18
-0
lines changed

module/rdpClientCon.c

Lines changed: 18 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -971,14 +971,32 @@ rdpClientConProcessMsgClientInfo(rdpPtr dev, rdpClientCon *clientCon)
971971
{
972972
LLOGLN(0, (" client can not do new(color) cursor"));
973973
}
974+
/*
975+
TODO: Temporary workaround intended to support two different versions of the xrdp_client_info.h
976+
header due to a customer request. This should be removed as soon as convenient, probably before the next
977+
release. See https://github.com/neutrinolabs/xorgxrdp/issues/217
978+
*/
979+
#if CLIENT_INFO_CURRENT_VERSION == 20210723
974980
if (clientCon->client_info.monitorCount > 0)
981+
#else
982+
if (clientCon->client_info.display_sizes.monitorCount > 0)
983+
#endif
975984
{
976985
LLOGLN(0, (" client can do multimon"));
986+
#if CLIENT_INFO_CURRENT_VERSION == 20210723
977987
LLOGLN(0, (" client monitor data, monitorCount=%d", clientCon->client_info.monitorCount));
988+
#else
989+
LLOGLN(0, (" client monitor data, monitorCount=%d", clientCon->client_info.display_sizes.monitorCount));
990+
#endif
978991
clientCon->doMultimon = 1;
979992
dev->doMultimon = 1;
993+
#if CLIENT_INFO_CURRENT_VERSION == 20210723
980994
memcpy(dev->minfo, clientCon->client_info.minfo, sizeof(dev->minfo));
981995
dev->monitorCount = clientCon->client_info.monitorCount;
996+
#else
997+
memcpy(dev->minfo, clientCon->client_info.display_sizes.minfo, sizeof(dev->minfo));
998+
dev->monitorCount = clientCon->client_info.display_sizes.monitorCount;
999+
#endif
9821000

9831001
box.x1 = dev->minfo[0].left;
9841002
box.y1 = dev->minfo[0].top;

0 commit comments

Comments
 (0)