msi: Free records on error paths (Coverity).

This commit is contained in:
Nikolay Sivov 2013-03-31 14:59:33 +04:00 committed by Alexandre Julliard
parent 3f3404d248
commit 58bbe5ac4c
2 changed files with 7 additions and 0 deletions

View File

@ -1376,7 +1376,10 @@ static UINT merge_verify_colnames(MSIQUERY *dbview, MSIQUERY *mergeview)
r = MSI_ViewGetColumnInfo(mergeview, MSICOLINFO_NAMES, &mergerec);
if (r != ERROR_SUCCESS)
{
msiobj_release(&dbrec->hdr);
return r;
}
count = MSI_RecordGetFieldCount(dbrec);
for (i = 1; i <= count; i++)
@ -1401,7 +1404,10 @@ static UINT merge_verify_colnames(MSIQUERY *dbview, MSIQUERY *mergeview)
r = MSI_ViewGetColumnInfo(mergeview, MSICOLINFO_TYPES, &mergerec);
if (r != ERROR_SUCCESS)
{
msiobj_release(&dbrec->hdr);
return r;
}
count = MSI_RecordGetFieldCount(dbrec);
for (i = 1; i <= count; i++)

View File

@ -3552,6 +3552,7 @@ static LRESULT msi_dialog_oncreate( HWND hwnd, LPCREATESTRUCTW cs )
if (!dialog->default_font)
{
dialog->default_font = strdupW(dfv);
msiobj_release( &rec->hdr );
if (!dialog->default_font) return -1;
}