From: Giovanni Panozzo Date: Sun, 21 Feb 2016 16:52:52 +0000 (+0100) Subject: Fix char signedness in glyph offset calculation, fixes #2137 X-Git-Tag: 2.0.0-beta1+android10~308^2 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=1dea98026ad8c6d1bd811a40effe7db889945a05;p=platform%2Fupstream%2Ffreerdp.git Fix char signedness in glyph offset calculation, fixes #2137 --- diff --git a/libfreerdp/cache/glyph.c b/libfreerdp/cache/glyph.c index 0157d40..412c114 100644 --- a/libfreerdp/cache/glyph.c +++ b/libfreerdp/cache/glyph.c @@ -57,7 +57,7 @@ void update_process_glyph(rdpContext* context, BYTE* data, int* index, if (offset & 0x80) { - offset = data[*index + 1] | ((int)((char)data[*index + 2]) << 8); + offset = data[*index + 1] | ((int)((signed char)data[*index + 2]) << 8); (*index)++; (*index)++; }