From: Arran Cudbard-Bell Date: Tue, 26 Jul 2022 15:50:38 +0000 (+0800) Subject: Deal with edge case in LDAP cancellations X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=b105bc45b9249b394e9a2d6eab6270f86d3c6a18;p=thirdparty%2Ffreeradius-server.git Deal with edge case in LDAP cancellations --- diff --git a/src/lib/ldap/base.c b/src/lib/ldap/base.c index 9028c5ab6b2..bfa92b9862b 100644 --- a/src/lib/ldap/base.c +++ b/src/lib/ldap/base.c @@ -612,6 +612,11 @@ static void ldap_trunk_query_cancel(UNUSED request_t *request, fr_state_signal_t fr_ldap_query_t *query = talloc_get_type_abort(uctx, fr_ldap_query_t); if (action != FR_SIGNAL_CANCEL) return; + /* + * Query may have completed, but the request + * not yet have been resumed. + */ + if (!query->treq) return; fr_trunk_request_signal_cancel(query->treq);