mirror of
https://github.com/gryf/wmaker.git
synced 2025-12-19 04:20:27 +01:00
WINGs: fix memory leak in WMSubtractPLDictionaries (Coverity #50128)
As pointed by Coverity, a temporary proplist is created with the list of keys to be removed from the source proplist, but this temporary proplist was not released at the end, leaking memory. Signed-off-by: Christophe CURIS <christophe.curis@free.fr>
This commit is contained in:
committed by
Carlos R. Mafra
parent
ba8cd2abe4
commit
15db368291
@@ -1213,6 +1213,7 @@ WMPropList *WMSubtractPLDictionaries(WMPropList * dest, WMPropList * source, Boo
|
|||||||
for (i = 0; i < WMGetArrayItemCount(keys->d.array); i++) {
|
for (i = 0; i < WMGetArrayItemCount(keys->d.array); i++) {
|
||||||
WMRemoveFromPLDictionary(dest, WMGetFromArray(keys->d.array, i));
|
WMRemoveFromPLDictionary(dest, WMGetFromArray(keys->d.array, i));
|
||||||
}
|
}
|
||||||
|
WMReleasePropList(keys);
|
||||||
return dest;
|
return dest;
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user