Changeset 411666a for lib/protocols_transport.c
- Timestamp:
- 12/19/07 11:17:58 (13 years ago)
- Branches:
- 4.0.1-hotfixes, cachetimestamps, develop, dpdk-ndag, etsilive, getfragoff, help, libtrace4, master, ndag_format, pfring, rc-4.0.1, rc-4.0.2, rc-4.0.3, rc-4.0.4, ringdecrementfix, ringperformance, ringtimestampfixes
- Children:
- a78665c
- Parents:
- 287b2b4
- File:
-
- 1 edited
Legend:
- Unmodified
- Added
- Removed
-
lib/protocols_transport.c
ra81d2fc r411666a 19 19 transport = trace_get_layer3(packet,ðertype,remaining); 20 20 21 if (!transport )21 if (!transport || *remaining == 0) 22 22 return NULL; 23 23 … … 118 118 { 119 119 if (remaining) { 120 if (*remaining < sizeof(libtrace_udp_t))120 if (*remaining <= sizeof(libtrace_udp_t)) 121 121 return NULL; 122 122 *remaining-=sizeof(libtrace_udp_t); … … 129 129 unsigned int dlen = tcp->doff*4; 130 130 if (remaining) { 131 if (*remaining < dlen)131 if (*remaining <= dlen) 132 132 return NULL; 133 133 *remaining-=dlen; … … 139 139 { 140 140 if (remaining) { 141 if (*remaining < sizeof(libtrace_icmp_t))141 if (*remaining <= sizeof(libtrace_icmp_t)) 142 142 return NULL; 143 143 *remaining-=sizeof(libtrace_icmp_t);
Note: See TracChangeset
for help on using the changeset viewer.