[MSRLE32] Sync with Wine Staging 4.18. CORE-16441
[reactos.git] / dll / win32 / msrle32 / msrle32.c
index 5bcfa86..5b17b25 100644 (file)
@@ -1544,6 +1544,11 @@ static LRESULT CompressEnd(CodecInfo *pi)
     pi->pCurFrame  = NULL;
     pi->nPrevFrame = -1;
     pi->bCompress  = FALSE;
+
+    if (pi->palette_map != NULL) {
+        LocalFree(pi->palette_map);
+        pi->palette_map = NULL;
+    }
   }
 
   return ICERR_OK;