]> git.ipfire.org Git - thirdparty/suricata.git/commitdiff
htp: hide BUG_ON's behind DEBUG_VALIDATION
authorVictor Julien <victor@inliniac.net>
Fri, 19 Jun 2015 11:05:49 +0000 (13:05 +0200)
committerVictor Julien <victor@inliniac.net>
Fri, 19 Jun 2015 11:05:49 +0000 (13:05 +0200)
src/app-layer-htp.c

index d561f0868f98d1330a669f7c4e7aa372942d0312..8444afe651ed6b718b50b9cdb3840cf8443b6075 100644 (file)
@@ -702,7 +702,9 @@ static int HTPHandleRequestData(Flow *f, void *htp_state,
         }
 
         if (NULL == htp) {
+#ifdef DEBUG_VALIDATION
             BUG_ON(htp == NULL);
+#endif
             /* should never happen if HTPConfigure is properly invoked */
             goto error;
         }
@@ -721,7 +723,9 @@ static int HTPHandleRequestData(Flow *f, void *htp_state,
     }
 
     /* the code block above should make sure connp is never NULL here */
+#ifdef DEBUG_VALIDATION
     BUG_ON(hstate->connp == NULL);
+#endif
 
     /* Unset the body inspection (the callback should
      * reactivate it if necessary) */