From 91b7aa2d5f1f8bbcb6d62c33973cceef48b5846e Mon Sep 17 00:00:00 2001 From: david Date: Thu, 29 Sep 2011 22:23:14 +0000 Subject: [PATCH] Don't use strict inequality with MAX_LINK_HEADERSZ. DLT_IPNET is equal to this. --- tcpip.cc | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/tcpip.cc b/tcpip.cc index e74455311..9bcdd6f10 100644 --- a/tcpip.cc +++ b/tcpip.cc @@ -1653,7 +1653,7 @@ char *readip_pcap(pcap_t *pd, unsigned int *len, long to_usec, if (offset && linknfo) { linknfo->datalinktype = datalink; linknfo->headerlen = offset; - assert(offset < MAX_LINK_HEADERSZ); + assert(offset <= MAX_LINK_HEADERSZ); memcpy(linknfo->header, p, MIN(sizeof(linknfo->header), offset)); } p += offset;