Actions
Bug #4168
closedNapatech: Double release of packet possible in certain error cases.
Description
p->ReleasePacket = NapatechReleasePacket; p->ntpv.nt_packet_buf = packet_buffer; p->ntpv.stream_id = ntv->stream_id; p->datalink = LINKTYPE_ETHERNET; if (unlikely(PacketSetData(p, (uint8_t *)NT_NET_GET_PKT_L2_PTR(packet_buffer), NT_NET_GET_PKT_WIRE_LENGTH(packet_buffer)))) { TmqhOutputPacketpool(ntv->tv, p); NT_NetRxRelease(ntv->rx_stream, packet_buffer); SCReturnInt(TM_ECODE_FAILED); }
When "PacketSetData" fails, the packet buffer will be released twice
- TmqhOutputPacketpool calls "p->ReleasePacket" which calls "NT_NetRxRelease"
- Direct call to NT_NetRxRelease
Actions