mirror of
https://github.com/reactos/wine.git
synced 2024-11-26 13:10:28 +00:00
Avoid accessing an uninitialized string in the failure case.
This commit is contained in:
parent
c5de0253cd
commit
3fe9aa2054
@ -109,10 +109,12 @@ void test_sid()
|
||||
ok( r, "failed to allocate sid\n" );
|
||||
r = pConvertSidToStringSidA( psid, &str );
|
||||
ok( r, "failed to convert sid\n" );
|
||||
ok( !strcmp( str, refs[i].refStr ),
|
||||
"incorrect sid, expected %s, got %s\n", refs[i].refStr, str );
|
||||
if( str )
|
||||
if (r)
|
||||
{
|
||||
ok( !strcmp( str, refs[i].refStr ),
|
||||
"incorrect sid, expected %s, got %s\n", refs[i].refStr, str );
|
||||
LocalFree( str );
|
||||
}
|
||||
if( psid )
|
||||
FreeSid( psid );
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user