summaryrefslogtreecommitdiffstats
path: root/libxrdp
diff options
context:
space:
mode:
authorJay Sorg <jay.sorg@gmail.com>2013-07-09 21:34:20 -0700
committerJay Sorg <jay.sorg@gmail.com>2013-07-09 21:34:20 -0700
commit14a4ac5a791882ad2171a522ce146fbba02bb4c7 (patch)
treea0d1028ca422956ab5465b8be50c34d2a2c3f902 /libxrdp
parentd2915f349a6b885cafbc549cea29ab6a541626ed (diff)
downloadxrdp-proprietary-14a4ac5a791882ad2171a522ce146fbba02bb4c7.tar.gz
xrdp-proprietary-14a4ac5a791882ad2171a522ce146fbba02bb4c7.zip
libxrdp: started adding fastpath support
Diffstat (limited to 'libxrdp')
-rw-r--r--libxrdp/xrdp_rdp.c24
1 files changed, 21 insertions, 3 deletions
diff --git a/libxrdp/xrdp_rdp.c b/libxrdp/xrdp_rdp.c
index 624b3b5d..82ccdea0 100644
--- a/libxrdp/xrdp_rdp.c
+++ b/libxrdp/xrdp_rdp.c
@@ -625,8 +625,16 @@ xrdp_rdp_send_demand_active(struct xrdp_rdp *self)
out_uint16_le(s, 0x200); /* Protocol version */
out_uint16_le(s, 0); /* pad */
out_uint16_le(s, 0); /* Compression types */
- //out_uint16_le(s, 0); /* pad use 0x40d for rdp packets, 0 for not */
- out_uint16_le(s, 0x40d); /* pad use 0x40d for rdp packets, 0 for not */
+ /* NO_BITMAP_COMPRESSION_HDR 0x0400
+ FASTPATH_OUTPUT_SUPPORTED 0x0001 */
+ if (self->client_info.use_fast_path & 1)
+ {
+ out_uint16_le(s, 0x401);
+ }
+ else
+ {
+ out_uint16_le(s, 0x400);
+ }
out_uint16_le(s, 0); /* Update capability */
out_uint16_le(s, 0); /* Remote unshare capability */
out_uint16_le(s, 0); /* Compression level */
@@ -761,7 +769,17 @@ xrdp_rdp_send_demand_active(struct xrdp_rdp *self)
caps_count++;
out_uint16_le(s, RDP_CAPSET_INPUT); /* 13(0xd) */
out_uint16_le(s, RDP_CAPLEN_INPUT); /* 88(0x58) */
- out_uint8(s, 1);
+ if (self->client_info.use_fast_path & 2)
+ {
+ /* INPUT_FLAG_SCANCODES 0x0001
+ INPUT_FLAG_FASTPATH_INPUT 0x0008
+ INPUT_FLAG_FASTPATH_INPUT2 0x0020 */
+ out_uint8(s, 1 | 8 | 0x20);
+ }
+ else
+ {
+ out_uint8(s, 1);
+ }
out_uint8s(s, 83);
/* Remote Programs Capability Set */