Hello community, here is the log from the commit of package xrdp for openSUSE:Factory checked in at 2017-04-11 09:41:30 ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Comparing /work/SRC/openSUSE:Factory/xrdp (Old) and /work/SRC/openSUSE:Factory/.xrdp.new (New) ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
Package is "xrdp" Tue Apr 11 09:41:30 2017 rev:4 rq:485038 version:0.9.0~git.1456906198.f422461 Changes: -------- --- /work/SRC/openSUSE:Factory/xrdp/xrdp.changes 2017-02-21 13:50:53.535777746 +0100 +++ /work/SRC/openSUSE:Factory/.xrdp.new/xrdp.changes 2017-04-11 09:41:32.099832792 +0200 @@ -1,0 +2,9 @@ +Mon Feb 6 10:31:26 UTC 2017 - [email protected] + +- Add xrdp-fate319683-allow-vnc-resizing.patch: + Add support for ExtendedDesktopSize VNC extension into xrdp's VNC + client to allow it to do resizing, so that returning clients can + reconnect to session if their resolutions changed (FATE#319683, + bsc#948062). + +------------------------------------------------------------------- New: ---- xrdp-fate319683-allow-vnc-resizing.patch ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++ Other differences: ------------------ ++++++ xrdp.spec ++++++ --- /var/tmp/diff_new_pack.YoX2kA/_old 2017-04-11 09:41:33.311661605 +0200 +++ /var/tmp/diff_new_pack.YoX2kA/_new 2017-04-11 09:41:33.315661040 +0200 @@ -52,6 +52,8 @@ Patch13: xrdp-bsc965647-allow-admin-choose-desktop.patch # PATCH-FEATURE-SLE xrdp-fate318398-change-expired-password.patch fate#318398 - [email protected] -- enable user to update expired password via PAM Patch14: xrdp-fate318398-change-expired-password.patch +# PATCH-FEATURE-SLE xrdp-fate319683-allow-vnc-resizing.patch fate#319683 bsc#948062 - [email protected] -- allow resizing in VNC sessions +Patch15: xrdp-fate319683-allow-vnc-resizing.patch # PATCH-FIX-OPENSUSE xrdp-openSUSE-logo.patch - [email protected] -- use openSUSE logo in login dialog Patch21: xrdp-openSUSE-logo.patch BuildRequires: autoconf @@ -88,6 +90,7 @@ %patch12 -p1 %patch13 -p1 %patch14 -p1 +%patch15 -p1 %else %patch21 -p1 %endif ++++++ xrdp-fate319683-allow-vnc-resizing.patch ++++++ diff --git a/sesman/session.c b/sesman/session.c index 4ea48d3..def4179 100644 --- a/sesman/session.c +++ b/sesman/session.c @@ -105,7 +105,6 @@ session_get_bydata(char *name, int width, int height, int bpp, int type, char *c { case SCP_SESSION_TYPE_XVNC: /* 0 */ type = SESMAN_SESSION_TYPE_XVNC; /* 2 */ - policy |= SESMAN_CFG_SESS_POLICY_D; /* Xvnc cannot resize */ break; case SCP_SESSION_TYPE_XRDP: /* 1 */ type = SESMAN_SESSION_TYPE_XRDP; /* 1 */ diff --git a/vnc/vnc.c b/vnc/vnc.c index c3ee3bf..03bb5b5 100644 --- a/vnc/vnc.c +++ b/vnc/vnc.c @@ -359,7 +359,8 @@ lib_mod_event(struct vnc *v, int msg, long param1, long param2, /* FrambufferUpdateRequest */ init_stream(s, 8192); out_uint8(s, 3); - out_uint8(s, 0); + out_uint8(s, v->incremental); + v->incremental = 1; x = (param1 >> 16) & 0xffff; out_uint16_be(s, x); y = param1 & 0xffff; @@ -707,7 +708,24 @@ lib_framebuffer_update(struct vnc *v) { v->mod_width = cx; v->mod_height = cy; - error = v->server_reset(v, cx, cy, v->mod_bpp); + } + else if (encoding == 0xfffffecc) /* extended desktop resize */ + { + init_stream(s, 8192); + error = lib_recv(v, s->data, 4); + if (error == 0) + { + in_uint8(s, k); /* number of screens */ + in_uint8s(s, 3); + error = lib_recv(v, s->data, k * 16); + if (error == 0) + { + in_uint8s(s, k * 16); /* skip screen list */ + /* note new dimensions for later */ + v->server_width = cx; + v->server_height = cy; + } + } } else { @@ -724,13 +742,23 @@ lib_framebuffer_update(struct vnc *v) } g_free(data); + free_stream(s); + if (v->mod_width != v->server_width || v->mod_height != v->server_height) + { + /* perform actual resize outside the update */ + v->mod_width = v->server_width; + v->mod_height = v->server_height; + error = v->server_reset(v, v->mod_width, v->mod_height, v->mod_bpp); + v->incremental = 0; + } if (error == 0) { /* FrambufferUpdateRequest */ init_stream(s, 8192); out_uint8(s, 3); - out_uint8(s, 1); + out_uint8(s, v->incremental); + v->incremental = 1; out_uint16_be(s, 0); out_uint16_be(s, 0); out_uint16_be(s, v->mod_width); @@ -1238,13 +1266,14 @@ lib_mod_connect(struct vnc *v) init_stream(s, 8192); out_uint8(s, 2); out_uint8(s, 0); - out_uint16_be(s, 4); + out_uint16_be(s, 5); out_uint32_be(s, 0); /* raw */ out_uint32_be(s, 1); /* copy rect */ out_uint32_be(s, 0xffffff11); /* cursor */ out_uint32_be(s, 0xffffff21); /* desktop size */ + out_uint32_be(s, 0xfffffecc); /* extended desktop resize */ v->server_msg(v, "VNC sending encodings", 0); - error = lib_send(v, s->data, 4 + 4 * 4); + error = lib_send(v, s->data, 4 + 5 * 4); } if (error == 0) @@ -1257,7 +1286,8 @@ lib_mod_connect(struct vnc *v) /* FrambufferUpdateRequest */ init_stream(s, 8192); out_uint8(s, 3); - out_uint8(s, 0); + out_uint8(s, v->incremental); + v->incremental = 1; out_uint16_be(s, 0); out_uint16_be(s, 0); out_uint16_be(s, v->mod_width); diff --git a/vnc/vnc.h b/vnc/vnc.h index 6d265be..69e899b 100644 --- a/vnc/vnc.h +++ b/vnc/vnc.h @@ -116,4 +116,5 @@ struct vnc int clip_data_size; tbus sck_obj; int delay_ms; + int incremental; };
