From efe9cf67c50e98fa03ff41640ae7988d68a51e90 Mon Sep 17 00:00:00 2001 From: Theo Buehler Date: Wed, 20 Mar 2024 21:21:04 +0000 Subject: Make module_free() NULL safe ok jsing --- lib/libcrypto/conf/conf_mod.c | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/lib/libcrypto/conf/conf_mod.c b/lib/libcrypto/conf/conf_mod.c index aab108a2602..f1a88c92b3d 100644 --- a/lib/libcrypto/conf/conf_mod.c +++ b/lib/libcrypto/conf/conf_mod.c @@ -1,4 +1,4 @@ -/* $OpenBSD: conf_mod.c,v 1.28 2023/07/20 15:05:30 tb Exp $ */ +/* $OpenBSD: conf_mod.c,v 1.29 2024/03/20 21:21:03 tb Exp $ */ /* Written by Stephen Henson (steve@openssl.org) for the OpenSSL * project 2001. */ @@ -364,6 +364,9 @@ CONF_modules_unload(int all) static void module_free(CONF_MODULE *md) { + if (md == NULL) + return; + free(md->name); free(md); } -- cgit v1.2.3