git: wg: Port #30: replace m_get2() with m_getl()

Aaron LI aly at crater.dragonflybsd.org
Thu Feb 8 00:32:31 PST 2024


commit bd36992fc0f235b262366df0c103c208f8469af0
Author: Aaron LI <aly at aaronly.me>
Date:   Sun Nov 26 10:52:25 2023 +0800

    wg: Port #30: replace m_get2() with m_getl()
    
    Our m_getl() has the similar semantics to FreeBSD's m_get2(): it will
    allocate an mbuf cluster if the requested size is big enough.  However,
    m_getl() wouldn't return NULL simply because the requested size exceeds
    the cluster size (MCLBYTES), but FreeBSD's m_get2() would just return
    NULL, which is OK because the wg_send_buf() only sends handshake packets
    of known and limited lengths.

Summary of changes:
 sys/net/wg/if_wg.c | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

http://gitweb.dragonflybsd.org/dragonfly.git/commitdiff/bd36992fc0f235b262366df0c103c208f8469af0


-- 
DragonFly BSD source repository


More information about the Commits mailing list