From 6974817f72bbb31540c3bcff0dfe38a1161e7451 Mon Sep 17 00:00:00 2001 From: Tom DeCanio Date: Tue, 12 Nov 2013 17:45:56 -0800 Subject: [PATCH] remove dead JSON DNS output code --- src/output-dnslog.c | 34 ---------------------------------- 1 file changed, 34 deletions(-) diff --git a/src/output-dnslog.c b/src/output-dnslog.c index 3729b5aee7..78cf266617 100644 --- a/src/output-dnslog.c +++ b/src/output-dnslog.c @@ -269,40 +269,6 @@ end: SCReturnInt(TM_ECODE_OK); } -#if 0 -int OutputDnsNeedsLog(Packet *p) -{ - SCEnter(); - - /* no flow, no htp state */ - if (p->flow == NULL) { - SCReturnInt(0); - } - - if (!(PKT_IS_UDP(p)) && !(PKT_IS_TCP(p))) { - SCReturnInt(0); - } - - /* check if we have DNS state or not */ - FLOWLOCK_WRLOCK(p->flow); - uint16_t proto = AppLayerGetProtoFromPacket(p); - if (proto != ALPROTO_DNS_UDP && proto != ALPROTO_DNS_TCP) { - SCLogDebug("proto not ALPROTO_DNS_UDP: %u", proto); - goto end; - } - - DNSState *dns_state = (DNSState *)AppLayerGetProtoStateFromPacket(p); - if (dns_state == NULL) { - SCLogDebug("no dns state, so no request logging"); - goto end; - } -end: - FLOWLOCK_UNLOCK(p->flow); - - SCReturnInt(1); -} -#endif - TmEcode OutputDnsLog(ThreadVars *tv, Packet *p, void *data, PacketQueue *pq, PacketQueue *postpq) { SCEnter();