]> git.ipfire.org Git - thirdparty/squid.git/commitdiff
assertions
authorwessels <>
Tue, 24 Feb 1998 23:43:22 +0000 (23:43 +0000)
committerwessels <>
Tue, 24 Feb 1998 23:43:22 +0000 (23:43 +0000)
snmplib/parse.c

index ee4b47bb35e4b887d6294f4f3fc04453a16c932b..1c2769f2073c3f2badd19b54e42fc007bfe6f1db 100644 (file)
@@ -71,6 +71,10 @@ SOFTWARE.
 #if HAVE_NETDB_H
 #include <netdb.h>
 #endif
+#if HAVE_ASSERT_H
+#include <assert.h>
+#endif
+
 
 #include "asn1.h"
 #include "snmp_vars.h"
@@ -256,7 +260,9 @@ print_error(string, token, type)
     char *token;
     int type;
 {
-    if (type == ENDOFFILE && snmplib_debug)
+    assert(string != NULL);
+    assert(snmplib_debug != NULL);
+    if (type == ENDOFFILE)
        snmplib_debug(0, "%s(EOF): On or around line %d\n", string, Line);
     else if (token)
        snmplib_debug(0, "%s(%s): On or around line %d\n", string, token, Line);