From: Arran Cudbard-Bell Date: Tue, 6 Apr 2021 00:54:02 +0000 (+0100) Subject: Reset indent to 0 on stopped requests X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=f6b071e9dd6131b52c16c32cbd0a7dabb5e7ea1b;p=thirdparty%2Ffreeradius-server.git Reset indent to 0 on stopped requests --- diff --git a/src/lib/io/worker.c b/src/lib/io/worker.c index 7caea45963..24f3c76ee6 100644 --- a/src/lib/io/worker.c +++ b/src/lib/io/worker.c @@ -1062,8 +1062,8 @@ static void _worker_request_stop(request_t *request, void *uctx) /* * Make sure time tracking is always in a - * consistent state when we mark the request - * as done. + * consistent state when we mark the request + * as done. */ if (request->async->tracking.state == FR_TIME_TRACKING_YIELDED) { fr_time_tracking_resume(&request->async->tracking, fr_time()); @@ -1071,10 +1071,17 @@ static void _worker_request_stop(request_t *request, void *uctx) /* * If the request is in the runnable queue - * yank it back out, so it's not "runnable" + * yank it back out, so it's not "runnable" * when we call request done. */ if (fr_heap_entry_inserted(request->runnable_id)) fr_heap_extract(worker->runnable, request); + + /* + * The interpreter doesn't currently fix + * this for us, so we set the indent to 0 + * to avoid nasty asserts later. + */ + request->log.unlang_indent = 0; } /** Request is now runnable