]> git.ipfire.org Git - thirdparty/openldap.git/commitdiff
ITS#10344 Ensure the first argument passed to ber_dupbv_x is not NULL.
authorjinyaoguo <guo846@purdue.edu>
Wed, 28 May 2025 02:01:25 +0000 (22:01 -0400)
committerQuanah Gibson-Mount <quanah@openldap.org>
Fri, 20 Jun 2025 14:52:19 +0000 (14:52 +0000)
servers/slapd/schema_init.c
servers/slapd/schema_prep.c

index 5c0c6c959f427ee63419118f535b8b32f4ebdaca..d4ed9c58302461ecf743c65c670d04daa25907f5 100644 (file)
@@ -6159,7 +6159,7 @@ firstComponentNormalize(
        struct berval comp;
        ber_len_t len;
 
-       if( SLAP_MR_IS_VALUE_OF_ASSERTION_SYNTAX( usage )) {
+       if( normalized && SLAP_MR_IS_VALUE_OF_ASSERTION_SYNTAX( usage )) {
                ber_dupbv_x( normalized, val, ctx );
                return LDAP_SUCCESS;
        }
index fbf44cfaa318558fa84b250ec4dccebaab87c5c8..72cb72b9208e6fa6e8e00ad4e3e21e6ddf3389a8 100644 (file)
@@ -91,6 +91,7 @@ static int objectClassPretty(
        void *ctx )
 {
        ObjectClass *oc;
+       assert( out != NULL );
 
        if( oidValidate( NULL, in )) return LDAP_INVALID_SYNTAX;