]> git.ipfire.org Git - thirdparty/freeradius-server.git/commitdiff
add file / line for indent debugging
authorAlan T. DeKok <aland@freeradius.org>
Tue, 20 Sep 2022 16:11:53 +0000 (12:11 -0400)
committerAlan T. DeKok <aland@freeradius.org>
Tue, 20 Sep 2022 19:55:35 +0000 (15:55 -0400)
and move indent debugging to after the change, so it's clearer
what has been done where.

src/lib/server/log.h

index 2ca5b924d27762a727518f1fc10383aa8337f79f..528ad312102b2f87ba7572fefac209e5045c91dd 100644 (file)
@@ -404,12 +404,12 @@ typedef struct {
  *      only RINFO, RWARN, RERROR etc...
  */
 #  define RINDENT() do {\
-       RDEBUG4(">> (%i)", request->log.unlang_indent); \
        if (request->module) {\
                request->log.module_indent += 2;\
        } else {\
                request->log.unlang_indent += 2;\
        }\
+       RDEBUG4(">> (%i) %s[%u]", request->log.unlang_indent, __FILE__, __LINE__); \
 } while(0)
 
 /** Exdent (unindent) R* messages by one level
@@ -418,12 +418,12 @@ typedef struct {
  *      only RINFO, RWARN, RERROR etc...
  */
 #  define REXDENT() do {\
+       RDEBUG4("<< (%i) %s[%u]", request->log.unlang_indent, __FILE__, __LINE__); \
        if (request->module) {\
                request->log.module_indent -= 2;\
        } else {\
                request->log.unlang_indent -= 2;\
        }\
-       RDEBUG4("<< (%i)", request->log.unlang_indent); \
 } while(0)
 #else
 /** Indent R* messages by one level