about summary refs log tree commit diff
diff options
context:
space:
mode:
authorLaurent Bercot <ska-skaware@skarnet.org>2024-10-01 20:38:44 +0000
committerLaurent Bercot <ska@appnovation.com>2024-10-01 20:38:44 +0000
commitfaa51484fb1ea5f57d00004ab3ed74aa03fdd892 (patch)
treec0768330c5301d2d7d7758b1c389a05ac993d26d
parent645894afb11a4c5d60b4d4f6b55ba3c2f764d1c7 (diff)
downloaddnsfunnel-faa51484fb1ea5f57d00004ab3ed74aa03fdd892.tar.gz
dnsfunnel-faa51484fb1ea5f57d00004ab3ed74aa03fdd892.tar.xz
dnsfunnel-faa51484fb1ea5f57d00004ab3ed74aa03fdd892.zip
Add debug instruction
Signed-off-by: Laurent Bercot <ska@appnovation.com>
-rw-r--r--src/dnsfunnel/dnsfunneld.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/src/dnsfunnel/dnsfunneld.c b/src/dnsfunnel/dnsfunneld.c
index f57b265..6b830de 100644
--- a/src/dnsfunnel/dnsfunneld.c
+++ b/src/dnsfunnel/dnsfunneld.c
@@ -33,6 +33,8 @@
 #include <skalibs/gensetdyn.h>
 #include <skalibs/ip46.h>
 
+#include <skalibs/lolstdio.h>
+
 #include <s6-dns/s6dns.h>
 
 #include "dnsfunneld.h"
@@ -303,6 +305,7 @@ int main (int argc, char const *const *argv)
     x[0].events = IOPAUSE_READ ;
     x[1].fd = 0 ;
     x[1].events = (cont ? IOPAUSE_READ : 0) | (dfanswer_pending() ? IOPAUSE_WRITE : 0) ;
+    LOLDEBUG("loop: cont = %d, x[1].events = %u, inflight = %zu, pendingbytes = %zu", cont, (unsigned int)x[1].events, inflight, dfanswer_pending()) ;
     if (!x[1].events && !inflight) break ;
 
     while (i != sentinel)