From 140d1653cdffadc1170744856fd9e80e196b4f0a Mon Sep 17 00:00:00 2001 From: tb Date: Sat, 31 Aug 2024 09:46:17 +0000 Subject: [PATCH] Inline last use of CONF_free() This permits another single-use-no-longer-public API to join the party in the bit bucket. ok beck jsing --- lib/libcrypto/conf/conf_def.c | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/lib/libcrypto/conf/conf_def.c b/lib/libcrypto/conf/conf_def.c index 20bea03783d..0173a7117cd 100644 --- a/lib/libcrypto/conf/conf_def.c +++ b/lib/libcrypto/conf/conf_def.c @@ -1,4 +1,4 @@ -/* $OpenBSD: conf_def.c,v 1.43 2024/08/31 09:44:00 tb Exp $ */ +/* $OpenBSD: conf_def.c,v 1.44 2024/08/31 09:46:17 tb Exp $ */ /* Copyright (C) 1995-1998 Eric Young (eay@cryptsoft.com) * All rights reserved. * @@ -319,7 +319,10 @@ err: *line = eline; ERR_asprintf_error_data("line %ld", eline); if ((h != conf->data) && (conf->data != NULL)) { - CONF_free(conf->data); + CONF ctmp; + + CONF_set_nconf(&ctmp, conf->data); + ctmp.meth->destroy_data(&ctmp); conf->data = NULL; } if (v != NULL) { -- 2.20.1