set use_cache_glyph_v2 on if the client support

This commit is contained in:
daixj 2018-10-25 17:02:43 +08:00
parent 8da22cf67a
commit bc150c2e56
3 changed files with 3 additions and 9 deletions

View File

@ -367,7 +367,7 @@ xrdp_caps_process_glyphcache(struct xrdp_rdp *self, struct stream *s,
{
int glyph_support_level;
if (len < 40 + 4 + 2 + 2)
if (len < 40 + 4 + 2 + 2) /* MS-RDPBCGR 2.2.7.1.8 */
{
g_writeln("xrdp_caps_process_glyphcache: error");
return 1;
@ -378,9 +378,9 @@ xrdp_caps_process_glyphcache(struct xrdp_rdp *self, struct stream *s,
in_uint16_le(s, glyph_support_level);
in_uint8s(s, 2); /* pad */
if (self->client_info.use_cache_glyph_v2 && (glyph_support_level != 3))
if (glyph_support_level == GLYPH_SUPPORT_ENCODE)
{
self->client_info.use_cache_glyph_v2 = 0;
self->client_info.use_cache_glyph_v2 = 1;
}
g_writeln("xrdp_caps_process_glyphcache: support level %d ",
glyph_support_level);

View File

@ -275,10 +275,6 @@ xrdp_rdp_read_config(struct xrdp_client_info *client_info)
client_info->key_file, g_get_strerror());
}
}
else if (g_strcasecmp(item, "use_cache_glyph_v2") == 0)
{
client_info->use_cache_glyph_v2 = g_text2bool(value);
}
}

View File

@ -53,8 +53,6 @@ use_fastpath=both
#require_credentials=true
; You can set the PAM error text in a gateway setup (MAX 256 chars)
#pamerrortxt=change your password according to policy at http://url
; Cache Glyph Revison 2. default: false
use_cache_glyph_v2=true
;
; colors used by windows in RGB format