mirror of https://github.com/FreeRDP/FreeRDP
orders: Fix OFFSCREEN_DELETE_LIST allocation size
The size of OFFSCREEN_DELETE_LIST list allocation was incorrectly changed by commit99b1481
and consequently fixed incorrectly by commit8a0fe086
. Let's count the allocation size based on new size and not based on current size in order to prevent some memory issues. https://github.com/FreeRDP/FreeRDP/issues/4117
This commit is contained in:
parent
048e7f264b
commit
9cccd4888d
|
@ -2460,7 +2460,7 @@ static BOOL update_read_create_offscreen_bitmap_order(wStream* s,
|
|||
if (deleteList->cIndices > deleteList->sIndices)
|
||||
{
|
||||
UINT16* new_indices;
|
||||
new_indices = (UINT16*)realloc(deleteList->indices, deleteList->sIndices * 2);
|
||||
new_indices = (UINT16*)realloc(deleteList->indices, deleteList->cIndices * 2);
|
||||
|
||||
if (!new_indices)
|
||||
return FALSE;
|
||||
|
|
Loading…
Reference in New Issue