the request has been cancelled, but it might not be done.
typedef enum fr_state_signal_t { /* server action */
FR_SIGNAL_INVALID = 0,
FR_SIGNAL_RUN,
- FR_SIGNAL_DONE, //!< Request is completed. If a module is signalled
+ FR_SIGNAL_CANCEL, //!< Request has been cancelled. If a module is signalled
///< with this, the module should stop processing
- ///< the request and cleanup.
+ ///< the request and cleanup anything it's done.
FR_SIGNAL_DUP, //!< A duplicate request was received.
} fr_state_signal_t;
* stopped. This tells any child modules
* to clean up timers, etc.
*/
- unlang_signal(state->children[i].child, FR_SIGNAL_DONE);
+ unlang_signal(state->children[i].child, FR_SIGNAL_CANCEL);
TALLOC_FREE(state->children[i].child);
/* FALL-THROUGH */
/*
* Async (in the same thread, tho) signal to be done.
*/
- if (action == FR_SIGNAL_DONE) goto done;
+ if (action == FR_SIGNAL_CANCEL) goto done;
/*
* We ignore all other actions.
request->process(request, action);
break;
- case FR_SIGNAL_DONE:
+ case FR_SIGNAL_CANCEL:
(void) fr_heap_extract(request->backlog, request);
request_delete(request);
break;
REQUEST_VERIFY(request);
switch (action) {
- case FR_SIGNAL_DONE:
+ case FR_SIGNAL_CANCEL:
goto done;
default:
request->process(request, action);
break;
- case FR_SIGNAL_DONE:
+ case FR_SIGNAL_CANCEL:
(void) fr_heap_extract(request->backlog, request);
request_delete(request);
break;
static void mod_delay_cancel(REQUEST *request, UNUSED void *instance, UNUSED void *thread, void *ctx,
fr_state_signal_t action)
{
- if (action != FR_SIGNAL_DONE) return;
+ if (action != FR_SIGNAL_CANCEL) return;
RDEBUG2("Cancelling delay");
static void xlat_delay_cancel(REQUEST *request, UNUSED void *instance, UNUSED void *thread,
void *rctx, fr_state_signal_t action)
{
- if (action != FR_SIGNAL_DONE) return;
+ if (action != FR_SIGNAL_CANCEL) return;
RDEBUG2("Cancelling delay");
* the IO modules to do additional debugging if
* necessary.
*/
- if (action == FR_SIGNAL_DONE) {
+ if (action == FR_SIGNAL_CANCEL) {
talloc_free(link);
return;
}
/** Handle asynchronous cancellation of a request
*
- * If we're signalled that the request has been cancelled (FR_SIGNAL_DONE).
+ * If we're signalled that the request has been cancelled (FR_SIGNAL_CANCEL).
* Cleanup any pending state and release the connection handle back into the pool.
*
* @param[in] request being cancelled.
rlm_rest_thread_t *t = thread;
CURLMcode ret;
- if (action != FR_SIGNAL_DONE) return;
+ if (action != FR_SIGNAL_CANCEL) return;
RDEBUG("Forcefully cancelling pending REST request");
/** Handle asynchronous cancellation of a request
*
- * If we're signalled that the request has been cancelled (FR_SIGNAL_DONE).
+ * If we're signalled that the request has been cancelled (FR_SIGNAL_CANCEL).
* Cleanup any pending state and release the connection handle back into the pool.
*
* @param[in] request being cancelled.