diff options
Diffstat (limited to 'src/fnettrace-dns/main.c')
-rw-r--r-- | src/fnettrace-dns/main.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/src/fnettrace-dns/main.c b/src/fnettrace-dns/main.c index 32122754f..48bf14710 100644 --- a/src/fnettrace-dns/main.c +++ b/src/fnettrace-dns/main.c | |||
@@ -70,6 +70,7 @@ void print_dns(uint32_t ip_src, unsigned char *pkt) { | |||
70 | type, (nxdomain)? " NXDOMAIN": ""); | 70 | type, (nxdomain)? " NXDOMAIN": ""); |
71 | if (strcmp(tmp, last)) { | 71 | if (strcmp(tmp, last)) { |
72 | printf("%s\n", tmp); | 72 | printf("%s\n", tmp); |
73 | fflush(0); | ||
73 | strcpy(last, tmp); | 74 | strcpy(last, tmp); |
74 | } | 75 | } |
75 | 76 | ||
@@ -77,6 +78,7 @@ void print_dns(uint32_t ip_src, unsigned char *pkt) { | |||
77 | 78 | ||
78 | errout: | 79 | errout: |
79 | printf("%02d:%02d:%02d %15s Error: invalid DNS packet\n", t->tm_hour, t->tm_min, t->tm_sec, ip); | 80 | printf("%02d:%02d:%02d %15s Error: invalid DNS packet\n", t->tm_hour, t->tm_min, t->tm_sec, ip); |
81 | fflush(0); | ||
80 | } | 82 | } |
81 | 83 | ||
82 | // https://www.kernel.org/doc/html/latest/networking/filter.html | 84 | // https://www.kernel.org/doc/html/latest/networking/filter.html |