Commit f35356db authored by Huw D M Davies's avatar Huw D M Davies Committed by Alexandre Julliard

DPA_DeletePtr was resizing the array to a too small size.

parent be89816e
......@@ -1550,7 +1550,7 @@ DPA_DeletePtr (const HDPA hdpa, INT i)
/* free memory ?*/
if ((hdpa->nMaxCount - hdpa->nItemCount) >= hdpa->nGrow) {
INT nNewItems = MIN(hdpa->nGrow * 2, hdpa->nItemCount);
INT nNewItems = MAX(hdpa->nGrow * 2, hdpa->nItemCount);
nSize = nNewItems * sizeof(LPVOID);
lpDest = (LPVOID)HeapReAlloc (hdpa->hHeap, HEAP_ZERO_MEMORY,
hdpa->ptrs, nSize);
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment