mirror of
https://github.com/FreeRDP/FreeRDP.git
synced 2024-11-23 18:03:30 +08:00
[gdi,gfx] Fix width and height on reset
Since gdi->width and height are signed, use the MAX(0,gdi->width)
This commit is contained in:
parent
4284d67088
commit
7a037d80df
@ -137,8 +137,8 @@ static UINT gdi_ResetGraphics(RdpgfxClientContext* context,
|
||||
|
||||
if (!freerdp_settings_get_bool(gdi->context->settings, FreeRDP_DeactivateClientDecoding))
|
||||
{
|
||||
const UINT32 width = (UINT32)MIN(0, gdi->width);
|
||||
const UINT32 height = (UINT32)MIN(0, gdi->height);
|
||||
const UINT32 width = (UINT32)MAX(0, gdi->width);
|
||||
const UINT32 height = (UINT32)MAX(0, gdi->height);
|
||||
|
||||
if (!freerdp_client_codecs_reset(
|
||||
context->codecs, freerdp_settings_get_codecs_flags(settings), width, height))
|
||||
|
Loading…
Reference in New Issue
Block a user