[PATCH v2] wldap32: Fix memory leak on error path in create_page_control (cppcheck)
Alex Henrie
alexhenrie24 at gmail.com
Mon Dec 20 23:06:08 CST 2021
Signed-off-by: Alex Henrie <alexhenrie24 at gmail.com>
---
v2: Fix typo in commit message
---
dlls/wldap32/page.c | 1 +
1 file changed, 1 insertion(+)
diff --git a/dlls/wldap32/page.c b/dlls/wldap32/page.c
index 8b0ded40e35..9f4acbdaa16 100644
--- a/dlls/wldap32/page.c
+++ b/dlls/wldap32/page.c
@@ -96,6 +96,7 @@ static ULONG create_page_control( ULONG pagesize, struct berval *cookie, UCHAR c
}
if (!(ctrl->ldctl_oid = strAtoW( LDAP_PAGED_RESULT_OID_STRING )))
{
+ free( val );
free( ctrl );
return LDAP_NO_MEMORY;
}
--
2.34.1
More information about the wine-devel
mailing list