diff options
author | jsorg71 <jsorg71> | 2005-09-27 00:49:21 +0000 |
---|---|---|
committer | jsorg71 <jsorg71> | 2005-09-27 00:49:21 +0000 |
commit | 04f809251c57a21d25929f932cafe3d0ddb647e6 (patch) | |
tree | b5c57294ac55a58a96e0a6fcfdecc2c1cb9e9dd5 /libxrdp | |
parent | 967f6592d551d9a6cc18084bd22fa83c3df3fc56 (diff) | |
download | xrdp-proprietary-04f809251c57a21d25929f932cafe3d0ddb647e6.tar.gz xrdp-proprietary-04f809251c57a21d25929f932cafe3d0ddb647e6.zip |
8K max packet size for 8 bpp clients
Diffstat (limited to 'libxrdp')
-rw-r--r-- | libxrdp/xrdp_orders.c | 15 |
1 files changed, 12 insertions, 3 deletions
diff --git a/libxrdp/xrdp_orders.c b/libxrdp/xrdp_orders.c index 6289858f..66ccae7c 100644 --- a/libxrdp/xrdp_orders.c +++ b/libxrdp/xrdp_orders.c @@ -163,10 +163,19 @@ static int APP_CC xrdp_orders_check(struct xrdp_orders* self, int max_size) { int size; + int max_packet_size; + if (self->rdp_layer->client_info.bpp == 8) + { + max_packet_size = 8000; + } + else + { + max_packet_size = 16000; + } if (self->order_level < 1) { - if (max_size > 16000) + if (max_size > max_packet_size) { return 1; } @@ -176,11 +185,11 @@ xrdp_orders_check(struct xrdp_orders* self, int max_size) } } size = self->out_s->p - self->order_count_ptr; - if (size < 0 || size > 16384) + if (size < 0 || size > max_packet_size) { return 1; } - if (size + max_size + 100 > 16000) + if (size + max_size + 100 > max_packet_size) { xrdp_orders_force_send(self); xrdp_orders_init(self); |