msi: Check a return value (clang).

oldstable
Hans Leidekker 2011-01-27 11:56:08 +01:00 committed by Alexandre Julliard
parent 4a7371e32d
commit 53b5e7f319
1 changed files with 6 additions and 0 deletions

View File

@ -1130,6 +1130,12 @@ UINT WINAPI MsiSourceListAddSourceExW( LPCWSTR szProduct, LPCWSTR szUserSid,
RegCloseKey(sourcekey);
return ERROR_FUNCTION_FAILED;
}
if (rc != ERROR_SUCCESS)
{
ERR("can't open subkey %u\n", rc);
RegCloseKey(sourcekey);
return rc;
}
postfix = (dwOptions & MSISOURCETYPE_NETWORK) ? szBackSlash : szForwardSlash;
if (szSource[lstrlenW(szSource) - 1] == *postfix)