decode/icmpv6: remove unused error_ptr field

Was only set, never checked.

Part of effort to make Packet more compact.

Ticket: #6938.
pull/10971/head
Victor Julien 11 months ago committed by Victor Julien
parent 4b492c2ded
commit 18d49c27ae

@ -249,7 +249,6 @@ int DecodeICMPV6(ThreadVars *tv, DecodeThreadVars *dtv, Packet *p,
if (unlikely(len > ICMPV6_HEADER_LEN + USHRT_MAX)) {
return TM_ECODE_FAILED;
}
p->icmpv6vars.error_ptr= ICMPV6_GET_ERROR_PTR(p);
DecodePartialIPV6(p, (uint8_t *)(pkt + ICMPV6_HEADER_LEN),
(uint16_t)(len - ICMPV6_HEADER_LEN));
full_hdr = 1;

@ -113,9 +113,7 @@
/** If message is Error */
/** macro for icmpv6 "unused" access */
#define ICMPV6_GET_UNUSED(p) (p)->icmpv6h->icmpv6b.icmpv6e.unused
/** macro for icmpv6 "error_ptr" access */
#define ICMPV6_GET_ERROR_PTR(p) (p)->icmpv6h->icmpv6b.icmpv6e.error_ptr
#define ICMPV6_GET_UNUSED(p) (p)->icmpv6h->icmpv6b.icmpv6e.unused
/** macro for icmpv6 "mtu" accessibility */
// ICMPv6 has MTU only for type too big
#define ICMPV6_HAS_MTU(p) ((p)->icmpv6h->type == ICMP6_PACKET_TOO_BIG)
@ -156,8 +154,7 @@ typedef struct ICMPV6Vars_ {
/* checksum of the icmpv6 packet */
uint16_t id;
uint16_t seq;
uint32_t mtu;
uint32_t error_ptr;
uint32_t mtu;
/** Pointers to the embedded packet headers */
IPV6Hdr *emb_ipv6h;

Loading…
Cancel
Save