CVSROOT:        /cvs
Module name:    src
Changes by:     bl...@cvs.openbsd.org   2025/01/23 05:51:51

Modified files:
        sys/netinet    : ip_divert.c 
        sys/netinet6   : ip6_divert.c 

Log message:
Fix inpcb leak in divert attach.

All other internet socket attach functions first call soreserve()
and then in_pcballoc().  This avoids an in_pcbdetach() in the error
path.  Current divert attach code may leak the inpcb.  Reorder calls
to allow simple error handling.

OK mvs@

Reply via email to