From 1c70e4915fac837db146cd7cb024754318a4485a Mon Sep 17 00:00:00 2001 From: speidy Date: Sat, 18 Mar 2017 09:39:43 +0200 Subject: [PATCH] xrdp_orders_rail: fix resulting unicode length --- libxrdp/xrdp_orders_rail.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/libxrdp/xrdp_orders_rail.c b/libxrdp/xrdp_orders_rail.c index 0037b8ee..7bc7eed9 100644 --- a/libxrdp/xrdp_orders_rail.c +++ b/libxrdp/xrdp_orders_rail.c @@ -239,7 +239,7 @@ xrdp_orders_get_unicode_bytes(const char *text) else { /* calculate the number of bytes of the resulting null-terminated wide-string */ - num_chars = (num_chars + 1) * sizeof(twchar); + num_chars = (num_chars + 1) * 2; } return num_chars;