msi: Fix a leak of allocated string buffer on error path (Coverity).
This commit is contained in:
parent
dc33b13581
commit
c01c0b52ed
|
@ -370,7 +370,11 @@ static LPWSTR build_default_format(const MSIRECORD* record)
|
||||||
{
|
{
|
||||||
max_len = len;
|
max_len = len;
|
||||||
buf = msi_realloc(buf, (max_len + 1) * sizeof(WCHAR));
|
buf = msi_realloc(buf, (max_len + 1) * sizeof(WCHAR));
|
||||||
if (!buf) return NULL;
|
if (!buf)
|
||||||
|
{
|
||||||
|
msi_free(rc);
|
||||||
|
return NULL;
|
||||||
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
if (str)
|
if (str)
|
||||||
|
|
Loading…
Reference in New Issue