Fix memory leaks.
This commit is contained in:
parent
72faac0d2f
commit
41a04cc0de
|
@ -236,8 +236,11 @@ static UINT ControlEvent_SetTargetPath(MSIPACKAGE* package, LPCWSTR argument,
|
||||||
msi_dialog* dialog)
|
msi_dialog* dialog)
|
||||||
{
|
{
|
||||||
LPWSTR path = load_dynamic_property(package,argument, NULL);
|
LPWSTR path = load_dynamic_property(package,argument, NULL);
|
||||||
|
UINT r;
|
||||||
/* failure to set the path halts the executing of control events */
|
/* failure to set the path halts the executing of control events */
|
||||||
return MSI_SetTargetPathW(package, argument, path);
|
r = MSI_SetTargetPathW(package, argument, path);
|
||||||
|
HeapFree(GetProcessHeap(),0,path);
|
||||||
|
return r;
|
||||||
}
|
}
|
||||||
|
|
||||||
/*
|
/*
|
||||||
|
|
|
@ -276,6 +276,7 @@ LPWSTR resolve_folder(MSIPACKAGE *package, LPCWSTR name, BOOL source,
|
||||||
path = build_directory_name(2, check_path, NULL);
|
path = build_directory_name(2, check_path, NULL);
|
||||||
if (strcmpiW(path,check_path)!=0)
|
if (strcmpiW(path,check_path)!=0)
|
||||||
MSI_SetPropertyW(package,cszTargetDir,path);
|
MSI_SetPropertyW(package,cszTargetDir,path);
|
||||||
|
HeapFree(GetProcessHeap(),0,check_path);
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
{
|
{
|
||||||
|
|
Loading…
Reference in New Issue