MCPcopy Create free account
hub / github.com/F-Stack/f-stack / ip6_copypktopts

Function ip6_copypktopts

freebsd/netinet6/ip6_output.c:2786–2803  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2784#undef PKTOPT_EXTHDRCPY
2785
2786struct ip6_pktopts *
2787ip6_copypktopts(struct ip6_pktopts *src, int canwait)
2788{
2789 int error;
2790 struct ip6_pktopts *dst;
2791
2792 dst = malloc(sizeof(*dst), M_IP6OPT, canwait);
2793 if (dst == NULL)
2794 return (NULL);
2795 ip6_initpktopts(dst);
2796
2797 if ((error = copypktopts(dst, src, canwait)) != 0) {
2798 free(dst, M_IP6OPT);
2799 return (NULL);
2800 }
2801
2802 return (dst);
2803}
2804
2805void
2806ip6_freepcbopts(struct ip6_pktopts *pktopt)

Callers 1

tcp_syncache.cFile · 0.85

Calls 4

mallocFunction · 0.85
ip6_initpktoptsFunction · 0.85
copypktoptsFunction · 0.85
freeFunction · 0.50

Tested by

no test coverage detected