]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Enforce free ordering
authorArran Cudbard-Bell <a.cudbardb@freeradius.org>
Fri, 9 Apr 2021 21:22:56 +0000 (22:22 +0100)
committerArran Cudbard-Bell <a.cudbardb@freeradius.org>
Fri, 9 Apr 2021 21:23:41 +0000 (22:23 +0100)
src/modules/rlm_cipher/rlm_cipher.c

index 7f782280405610f016b9789664d501c0f0cef3b7..adbca70038f19621f3b3d8f5aa70aa783d5781bc 100644 (file)
@@ -464,7 +464,7 @@ static int cipher_rsa_certificate_file_load(TALLOC_CTX *ctx, void *out, UNUSED v
        }
 
        talloc_set_type(pkey, EVP_PKEY);
-       (void)talloc_steal(ctx, pkey);                  /* Bind lifetime to config */
+       (void)talloc_steal(cert, pkey);                 /* Bind lifetime to config */
        talloc_set_destructor(pkey, _evp_pkey_free);    /* Free pkey correctly on chunk free */
 
        rsa_inst->x509_certificate_file = cert;         /* Not great, but shouldn't cause any issues */