From 00948882e7e59b41982a0d5705428e41773579e2 Mon Sep 17 00:00:00 2001 From: Victor Julien Date: Mon, 22 Apr 2013 11:03:32 +0200 Subject: [PATCH] Suppress warnings when StreamSegmentForEach is called for UDP or SCTP, unless debug is compiled in. --- src/stream.c | 2 ++ 1 file changed, 2 insertions(+) diff --git a/src/stream.c b/src/stream.c index 6bb43dfea7..aec247e760 100644 --- a/src/stream.c +++ b/src/stream.c @@ -232,12 +232,14 @@ int StreamSegmentForEach(Packet *p, uint8_t flag, StreamSegmentCallback Callback case IPPROTO_TCP: return StreamTcpSegmentForEach(p, flag, CallbackFunc, data); break; +#ifdef DEBUG case IPPROTO_UDP: SCLogWarning(SC_ERR_UNKNOWN_PROTOCOL, "UDP is currently unsupported"); break; default: SCLogWarning(SC_ERR_UNKNOWN_PROTOCOL, "This protocol is currently unsupported"); break; +#endif } return 0; }