]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
ifdef out variables for assertions
authorAlan T. DeKok <aland@freeradius.org>
Thu, 19 Oct 2017 18:29:26 +0000 (14:29 -0400)
committerAlan T. DeKok <aland@freeradius.org>
Thu, 19 Oct 2017 18:29:26 +0000 (14:29 -0400)
src/main/unlang_interpret.c

index 9e7a2b4223aedb97b7d750cdeae3931ff886b134..57457bc70c0f22db2a1714f9f8a770ab9d446ae1 100644 (file)
@@ -2771,6 +2771,7 @@ void unlang_resumable(REQUEST *request)
                rad_assert(request->backlog == NULL);
                rad_assert(request->runnable_id < 0);
 
+#ifndef NDEBUG
                /*
                 *      Look at the current stack.
                 */
@@ -2782,6 +2783,7 @@ void unlang_resumable(REQUEST *request)
                 *      order for someone to mark it resumable.
                 */
                rad_assert(frame->instruction->type == UNLANG_TYPE_RESUME);
+#endif
 
                /*
                 *      Now look at the parents stack.  It also must
@@ -2823,6 +2825,8 @@ void unlang_resumable(REQUEST *request)
                parent = parent->parent;
        }
 
+
+#ifndef NDEBUG
        /*
         *      The current request MUST have been yielded in
         *      order for someone to mark it resumable.
@@ -2830,6 +2834,7 @@ void unlang_resumable(REQUEST *request)
        stack = request->stack;
        frame = &stack->frame[stack->depth];
        rad_assert(frame->instruction->type == UNLANG_TYPE_RESUME);
+#endif
 
        rad_assert(request->backlog != NULL);
        fr_heap_insert(request->backlog, request);