Ticket #261: Handled NULL bitmaps in guac_rdp_bitmap_setsurface and guac_rdp_gdi_memblt functions.
This commit is contained in:
parent
602e0045b6
commit
227afb3793
@ -183,6 +183,12 @@ void guac_rdp_bitmap_setsurface(rdpContext* context, rdpBitmap* bitmap, boolean
|
||||
|
||||
else {
|
||||
|
||||
/* Make sure that the recieved bitmap is not NULL before processing */
|
||||
if (bitmap == NULL) {
|
||||
guac_client_log_info(client, "NULL bitmap found in bitmap_setsurface instruction.");
|
||||
return;
|
||||
}
|
||||
|
||||
/* If not available as a surface, make available. */
|
||||
if (((guac_rdp_bitmap*) bitmap)->layer == NULL)
|
||||
guac_rdp_cache_bitmap(context, bitmap);
|
||||
|
@ -361,6 +361,13 @@ void guac_rdp_gdi_memblt(rdpContext* context, MEMBLT_ORDER* memblt) {
|
||||
int y_src = memblt->nYSrc;
|
||||
|
||||
rdp_guac_client_data* data = (rdp_guac_client_data*) client->data;
|
||||
|
||||
/* Make sure that the recieved bitmap is not NULL before processing */
|
||||
if (bitmap == NULL) {
|
||||
guac_client_log_info(client, "NULL bitmap found in memblt instruction.");
|
||||
return;
|
||||
}
|
||||
|
||||
pthread_mutex_lock(&(data->update_lock));
|
||||
|
||||
/* Clip operation to bounds */
|
||||
|
Loading…
Reference in New Issue
Block a user