Lines Matching refs:packet
14 void coap_packet_populate_endpoint(coap_packet_t *packet, coap_endpoint_t *target) in coap_packet_populate_endpoint() argument
18 void coap_packet_copy_source(coap_packet_t *packet, coap_address_t *target) in coap_packet_copy_source() argument
20 target->port = packet->srcport; in coap_packet_copy_source()
23 void coap_packet_get_memmapped(coap_packet_t *packet, unsigned char **address, size_t *length) in coap_packet_get_memmapped() argument
25 …nly deal with contiguous PBUFs to read the initial details", packet->pbuf->tot_len == packet->pbuf… in coap_packet_get_memmapped()
26 *address = packet->pbuf->payload; in coap_packet_get_memmapped()
27 *length = packet->pbuf->tot_len; in coap_packet_get_memmapped()
29 void coap_free_packet(coap_packet_t *packet) in coap_free_packet() argument
31 if (packet->pbuf) in coap_free_packet()
32 pbuf_free(packet->pbuf); in coap_free_packet()
33 coap_free_type(COAP_PACKET, packet); in coap_free_packet()
36 struct pbuf *coap_packet_extract_pbuf(coap_packet_t *packet) in coap_packet_extract_pbuf() argument
38 struct pbuf *ret = packet->pbuf; in coap_packet_extract_pbuf()
39 packet->pbuf = NULL; in coap_packet_extract_pbuf()
55 coap_packet_t *packet = coap_malloc_type(COAP_PACKET, sizeof(coap_packet_t)); in coap_recv() local
57 LWIP_ASSERT("Insufficient coap_packet_t resources.", packet != NULL); in coap_recv()
58 packet->pbuf = p; in coap_recv()
59 packet->srcport = port; in coap_recv()
62 coap_handle_message(ep->context, packet); in coap_recv()
64 coap_free_packet(packet); in coap_recv()