Wrap array accesses in macros, which also happen to be lvalues:

ifnet_addrs[i - 1]  -> ifaddr_byindex(i)
        ifindex2ifnet[i]    -> ifnet_byindex(i)

This is intended to ease the conversion to SMPng.

Forgotten by: jlemon
This commit is contained in:
Marcel Moolenaar 2001-09-08 04:20:45 +00:00
parent 0fe2f8cb85
commit 4fc33a34ae

View File

@ -202,7 +202,7 @@ osf1_ioctl_i(p, uap, cmd, dir, len)
* structure, as DU interface names are all different.
*/
for (ifn = 0; ifn < if_index; ifn++) {
ifp = ifnet_addrs[ifn]->ifa_ifp; /* pointer to interface */
ifp = ifnet_byindex(ifn);
/* Only look at ether interfaces, exclude alteon nics
* because osf/1 doesn't know about most of them.
*/