dsdb: Fix CID 1436919 Unchecked return value
authorVolker Lendecke <vl@samba.org>
Tue, 12 Jun 2018 19:12:47 +0000 (21:12 +0200)
committerAndrew Bartlett <abartlet@samba.org>
Wed, 13 Jun 2018 08:30:15 +0000 (10:30 +0200)
Signed-off-by: Volker Lendecke <vl@samba.org>
Reviewed-by: Andrew Bartlett <abartlet@samba.org>
source4/dsdb/samdb/ldb_modules/tests/test_audit_log.c

index 3e57af11a82ea3a8743ec889cf16024ee986a352..567c5b345d87907fd7d73b24930ceec5964ae8ed 100644 (file)
@@ -194,6 +194,7 @@ static void test_get_password_action(void **state)
        struct ldb_request *req = NULL;
        struct ldb_reply *reply = NULL;
        struct dsdb_control_password_acl_validation *pav = NULL;
+       int ret;
 
        TALLOC_CTX *ctx = talloc_new(NULL);
        ldb = ldb_init(ctx, NULL);
@@ -219,7 +220,8 @@ static void test_get_password_action(void **state)
        /*
         * dsdb_control_password_acl_validation reset = false, expect "Change"
         */
-       ldb_build_mod_req(&req, ldb, ctx, NULL, NULL, NULL, NULL, NULL);
+       ret = ldb_build_mod_req(&req, ldb, ctx, NULL, NULL, NULL, NULL, NULL);
+       assert_int_equal(ret, LDB_SUCCESS);
        reply = talloc_zero(ctx, struct ldb_reply);
        pav = talloc_zero(req, struct dsdb_control_password_acl_validation);