msi: Always check the return value of msi_string2idW.

This commit is contained in:
Hans Leidekker 2010-09-29 09:58:02 +02:00 committed by Alexandre Julliard
parent 2e1eb80c23
commit 2b2fa04ca4
2 changed files with 8 additions and 4 deletions

View File

@ -225,10 +225,12 @@ static UINT JOIN_get_column_info( struct tagMSIVIEW *view,
static UINT join_find_row( MSIJOINVIEW *jv, MSIRECORD *rec, UINT *row )
{
LPCWSTR str;
UINT i, id, data;
UINT r, i, id, data;
str = MSI_RecordGetString( rec, 1 );
msi_string2idW( jv->db->strings, str, &id );
r = msi_string2idW( jv->db->strings, str, &id );
if (r != ERROR_SUCCESS)
return r;
for (i = 0; i < jv->rows; i++)
{

View File

@ -334,10 +334,12 @@ static UINT STORAGES_get_column_info(struct tagMSIVIEW *view, UINT n,
static UINT storages_find_row(MSISTORAGESVIEW *sv, MSIRECORD *rec, UINT *row)
{
LPCWSTR str;
UINT i, id, data;
UINT r, i, id, data;
str = MSI_RecordGetString(rec, 1);
msi_string2idW(sv->db->strings, str, &id);
r = msi_string2idW(sv->db->strings, str, &id);
if (r != ERROR_SUCCESS)
return r;
for (i = 0; i < sv->num_rows; i++)
{