Allocate struct ipx_ifaddrs with an initial reference count of 1, not 0.
The wrong reference count was causing them to get freed too early and have their contents scrambled.
This commit is contained in:
parent
0f98df2956
commit
93997ef1c9
@ -142,6 +142,7 @@ ipx_control(so, cmd, data, ifp, td)
|
||||
ia = oia;
|
||||
ifa = (struct ifaddr *)ia;
|
||||
IFA_LOCK_INIT(ifa);
|
||||
ifa->ifa_refcnt = 1;
|
||||
TAILQ_INSERT_TAIL(&ifp->if_addrhead, ifa, ifa_link);
|
||||
ia->ia_ifp = ifp;
|
||||
ifa->ifa_addr = (struct sockaddr *)&ia->ia_addr;
|
||||
|
Loading…
Reference in New Issue
Block a user