From: Arran Cudbard-Bell Date: Tue, 26 Jul 2022 15:50:23 +0000 (+0800) Subject: Allow the transition from CANCEL to CANCEL_COMPLETE X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=ac75bcd993150f3a734c81f0966927322528c0cd;p=thirdparty%2Ffreeradius-server.git Allow the transition from CANCEL to CANCEL_COMPLETE --- diff --git a/src/lib/server/trunk.c b/src/lib/server/trunk.c index d602b831568..23b467b9b12 100644 --- a/src/lib/server/trunk.c +++ b/src/lib/server/trunk.c @@ -2184,6 +2184,19 @@ void fr_trunk_request_signal_cancel_complete(fr_trunk_request_t *treq) switch (treq->pub.state) { case FR_TRUNK_REQUEST_STATE_CANCEL_SENT: + /* + * This is allowed, as we may not need to wait + * for the database to ACK our cancellation + * request. + * + * Note: FR_TRUNK_REQUEST_STATE_CANCEL_PARTIAL + * is not allowed here, as that'd mean we'd half + * written the cancellation request out to the + * socket, and then decided to abandon it. + * + * That'd leave the socket in an unusable state. + */ + case FR_TRUNK_REQUEST_STATE_CANCEL: trunk_request_enter_cancel_complete(treq); break;