Each bitmap send by the server contains color depth. Even if we negotiated 8bpp server can send bitmap which has 16bpp.

Fix a crash using bpp to allocate image from the bitmap data instead of negotiated color depth.
This commit is contained in:
Pawel Jakub Dawidek 2012-01-31 14:33:49 +01:00
parent bb61820bfb
commit 19f99d66ba

View File

@ -43,7 +43,7 @@ void xf_Bitmap_New(rdpContext* context, rdpBitmap* bitmap)
if (bitmap->data != NULL)
{
data = freerdp_image_convert(bitmap->data, NULL,
bitmap->width, bitmap->height, xfi->srcBpp, xfi->bpp, xfi->clrconv);
bitmap->width, bitmap->height, bitmap->bpp, xfi->bpp, xfi->clrconv);
if (bitmap->ephemeral != true)
{