]> git.ipfire.org Git - thirdparty/openldap.git/commitdiff
ITS#9998 slapd-mtread: plug potential leak
authorHoward Chu <hyc@openldap.org>
Thu, 2 Feb 2023 15:17:28 +0000 (15:17 +0000)
committerQuanah Gibson-Mount <quanah@openldap.org>
Wed, 26 Apr 2023 17:31:01 +0000 (17:31 +0000)
tests/progs/slapd-mtread.c

index 587d3cf83702d7cc4056a82d6705f16524d8fa8f..bf6014ad5331178e54f46b739f971727ffd9d74d 100644 (file)
@@ -528,6 +528,7 @@ do_random( LDAP *ld,
                        if ( rc ) {
                                tester_ldap_error( ld, "ldap_search_ext_s", NULL );
                        }
+                       ldap_msgfree( res );
                        break;
                }
 
@@ -566,6 +567,7 @@ do_random( LDAP *ld,
 
        default:
                tester_ldap_error( ld, "ldap_search_ext_s", NULL );
+               ldap_msgfree( res );
                break;
        }