pbuf_realloc() is only used within LwIP.
 
Symbols
loading...
Files
loading...

pbuf_realloc() function

Shrink a pbuf chain to a desired length. Depending on the desired length, the first few pbufs in a chain might be skipped and left unchanged. The new last pbuf in the chain will be resized, and any remaining pbufs will be freed.

Syntax

void pbuf_realloc(struct pbuf *p,     u16_t size);
Implemented in pbuf.c:401

Arguments

p

pbuf to shrink.

size

Notes

If the pbuf is ROM/REF, only the ->tot_len and ->len fields are adjusted. May not be called on a packet queue. Despite its name, pbuf_realloc cannot grow the size of a pbuf (chain).

References

LocationReferrerText
pbuf.c:402
pbuf_realloc(struct pbuf *p, u16_t new_len)
pbuf.h:279
void pbuf_realloc(struct pbuf *p, u16_t size);
dhcp.c:1970dhcp_option_trailer()
pbuf_realloc(p_out, (u16_t)(sizeof(struct dhcp_msg) - DHCP_OPTIONS_LEN + options_out_len));
ip4.c:470ip4_input()
pbuf_realloc(p, iphdr_len);
tcp_in.c:1481tcp_receive()
pbuf_realloc(inseg.p, inseg.len);
tcp_out.c:932tcp_split_unsent_seg()
pbuf_realloc(useg->p, useg->p->tot_len - remainder);

Call Tree

Functions calling pbuf_realloc()
Functions called by pbuf_realloc()
pbuf_realloc()
printf()
all items filtered out
Data read by pbuf_realloc()
Data written by pbuf_realloc()
pbuf_realloc()::new_len
pbuf_realloc()::q
pbuf_realloc()::rem_len
pbuf_realloc()::shrink
all items filtered out
pbuf_realloc()
pbuf_realloc()::q
pbuf_realloc()::rem_len
pbuf_realloc()::shrink
all items filtered out
Type of pbuf_realloc()
pbuf_realloc()
all items filtered out