]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
Fix assert when trying to cancel new requests
authorArran Cudbard-Bell <a.cudbardb@freeradius.org>
Sat, 14 Dec 2019 12:21:02 +0000 (19:21 +0700)
committerArran Cudbard-Bell <a.cudbardb@freeradius.org>
Sat, 14 Dec 2019 12:21:02 +0000 (19:21 +0700)
src/lib/unlang/interpret.c

index 6318f9b27eb792bc230d10d12266ae75871353d7..9282fcb4a7aa23aae942fdc214a5ee68c4bac313 100644 (file)
@@ -1070,7 +1070,12 @@ void unlang_interpret_signal(REQUEST *request, fr_state_signal_t action)
                request->master_state = REQUEST_STOP_PROCESSING;
        }
 
-       frame_signal(request, action, 0);
+       /*
+        *      Requests that haven't been run through the interpreter
+        *      yet should have a stack depth of zero, so we don't
+        *      need to do anything.
+        */
+       if (request->stack->depth > 0) frame_signal(request, action, 0);
 }
 
 /** Return the depth of the request's stack