logo
Free, unlimited AI code reviews that run on commit
git-lrc git-lrc GitHub Install Now We'd appreciate a star git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt git-lrc - Free, unlimited AI code reviews that run on commit | Product Hunt

pcap_offline_filter - check whether a filter matches a packet

Description

pcap_offline_filter() checks whether a filter matches a packet. fp is a pointer to a bpf_program struct, usually the result of a call to pcap_compile(3PCAP). h points to the pcap_pkthdr structure for the packet, and pkt points to the data in the packet.

Name

pcap_offline_filter - check whether a filter matches a packet

Return Value

pcap_offline_filter() returns the return value of the filter program. This will be zero if the packet doesn't match the filter and non-zero if the packet matches the filter.

See Also

pcap(3PCAP) 7 April 2014 PCAP_OFFLINE_FILTER(3PCAP)

Synopsis

#include<pcap/pcap.h>intpcap_offline_filter(conststructbpf_program*fp,conststructpcap_pkthdr*h,constu_char*pkt);

See Also