]> The Tcpdump Group git mirrors - tcpdump/commitdiff
Fix the bounds check for the chunk.
authorguy <guy>
Fri, 6 May 2005 10:53:01 +0000 (10:53 +0000)
committerguy <guy>
Fri, 6 May 2005 10:53:01 +0000 (10:53 +0000)
print-sctp.c

index a491481bd21b0e2fd3cf254c58968842113133a2..b18ab793b09bbf31886c5116dec954d861a9bec2 100644 (file)
@@ -35,7 +35,7 @@
 
 #ifndef lint
 static const char rcsid[] _U_ =
-"@(#) $Header: /tcpdump/master/tcpdump/print-sctp.c,v 1.18 2005-05-05 23:08:43 guy Exp $ (NETLAB/PEL)";
+"@(#) $Header: /tcpdump/master/tcpdump/print-sctp.c,v 1.19 2005-05-06 10:53:01 guy Exp $ (NETLAB/PEL)";
 #endif
 
 #ifdef HAVE_CONFIG_H
@@ -146,7 +146,7 @@ void sctp_print(const u_char *bp,        /* beginning of sctp packet */
        break;
       }
 
-      TCHECK2(*(((u_int8_t *)chunkDescPtr) + chunkLength), chunkLength);
+      TCHECK2(*((u_int8_t *)chunkDescPtr), chunkLength);
       chunkEnd = ((const u_char*)chunkDescPtr + chunkLength);
 
       align=chunkLength % 4;