Re: [PATCH] advapi32: avoid memory leaks (Coverity)
3 Oct
2012
3 Oct
'12
4:16 p.m.
Marcus Meissner <marcus(a)jet.franken.de> writes:
@@ -530,8 +530,10 @@ static void test_enum_providers(void) /* alloc provider to half the size required * cbName holds the size required */ providerLen = cbName / 2; - if (!(provider = LocalAlloc(LMEM_ZEROINIT, providerLen))) + if (!(provider = LocalAlloc(LMEM_ZEROINIT, providerLen))) { + LocalFree(pszProvName); return; + }
Actually, checking for allocation failures in tests is not useful, it's not going to happen. -- Alexandre Julliard julliard(a)winehq.org
4817
Age (days ago)
4817
Last active (days ago)
0 comments
1 participants
participants (1)
-
Alexandre Julliard