22 #include "../../../utils/attributes.h"
93 #define __must_free_pcap_queue \
94 __attribute__((malloc(free_pcap_queue, 1))) __must_check
96 #define __must_free_pcap_queue __must_check
struct pcap_queue * push_pcap_queue(struct pcap_queue *queue, struct pcap_pkthdr *header, uint8_t *packet)
Pushes a packet in the pcap queue.
Definition: pcap_queue.c:35
__must_free_pcap_queue struct pcap_queue * init_pcap_queue(void)
Initialises an empty pcap queue.
Definition: pcap_queue.c:21
int is_pcap_queue_empty(struct pcap_queue *queue)
Checks if pcap queue is empty.
Definition: pcap_queue.c:102
void free_pcap_queue_el(struct pcap_queue *el)
Delete a pcap entry.
Definition: pcap_queue.c:81
ssize_t get_pcap_queue_length(struct pcap_queue *queue)
Returns the pcap queue length.
Definition: pcap_queue.c:98
struct pcap_queue * pop_pcap_queue(struct pcap_queue *queue)
Extract the first pcap element from the pcap queueu.
Definition: pcap_queue.c:74
void free_pcap_queue(struct pcap_queue *queue)
Frees the pcap queue.
Definition: pcap_queue.c:89
#define __must_free_pcap_queue
Definition: pcap_queue.h:96
pcap queueu structure definition
Definition: pcap_queue.h:28
struct dl_list list
Definition: pcap_queue.h:31
uint8_t * packet
Definition: pcap_queue.h:30
struct pcap_pkthdr header
Definition: pcap_queue.h:29