Go to the documentation of this file.
22 #ifndef NET_GNRC_PKT_H
23 #define NET_GNRC_PKT_H
120 #ifdef MODULE_GNRC_NETERR
138 while ((pkt != NULL) && (pkt->
next != snip)) {
155 while (pkt != NULL) {
232 while (pkt != NULL) {
256 while (pkt != NULL) {
static size_t gnrc_pkt_len_upto(const gnrc_pktsnip_t *pkt, gnrc_nettype_t type)
Calculates length of a packet in byte up to (including) a snip with the given type.
int16_t kernel_pid_t
Unique process identifier.
void * data
pointer to the data of the snip
static gnrc_pktsnip_t * gnrc_pkt_prepend(gnrc_pktsnip_t *pkt, gnrc_pktsnip_t *snip)
Prepends a snip to a packet.
static size_t gnrc_pkt_count(const gnrc_pktsnip_t *pkt)
Count the numbers of snips in the given packet.
static gnrc_pktsnip_t * gnrc_pkt_prev_snip(gnrc_pktsnip_t *pkt, gnrc_pktsnip_t *snip)
Returns the snip before a given snip in a packet.
gnrc_nettype_t type
protocol of the packet snip
struct gnrc_pktsnip gnrc_pktsnip_t
Type to represent parts (either headers or payload) of a packet, called snips.
Scheduler API definition.
static gnrc_pktsnip_t * gnrc_pkt_append(gnrc_pktsnip_t *pkt, gnrc_pktsnip_t *snip)
Appends a snip to a packet.
gnrc_pktsnip_t * gnrc_pktsnip_search_type(gnrc_pktsnip_t *pkt, gnrc_nettype_t type)
Searches the packet for a packet snip of a specific type.
Protocol type definitions.
gnrc_nettype_t
Definition of protocol types in the network stack.
struct list_node * next
pointer to next list entry
static list_node_t * list_remove(list_node_t *list, list_node_t *node)
Removes the node from the list.
static gnrc_pktsnip_t * gnrc_pkt_delete(gnrc_pktsnip_t *pkt, gnrc_pktsnip_t *snip)
Deletes a snip from a packet.
static size_t gnrc_pkt_len(const gnrc_pktsnip_t *pkt)
Calculates length of a packet in byte.
size_t size
the length of the snip in byte
struct gnrc_pktsnip * next
next snip in the packet
Adds include for missing inttype definitions.
unsigned int users
Counter of threads currently having control over this packet.
Type to represent parts (either headers or payload) of a packet, called snips.