summaryrefslogtreecommitdiffstats
path: root/if-bsd.c
diff options
context:
space:
mode:
authorRoy Marples <roy@marples.name>2009-03-23 10:09:10 +0000
committerRoy Marples <roy@marples.name>2009-03-23 10:09:10 +0000
commit45b51c7f6c5ca068d8d2a283eeb976465247dfde (patch)
treee508d215d090adffb46b3b5a71a8141c4404ed44 /if-bsd.c
parentd377fcaa7c3de0f105d65644244167ff81d93484 (diff)
downloaddhcpcd-45b51c7f6c5ca068d8d2a283eeb976465247dfde.tar.xz
dhcpcd CAN work on IEEE FireWire interfaces.
However, BPF does not appear to operate on these, so we report the error and continue. When BPF supports FireWire for DHCP, dhcpcd will magically start to work.
Diffstat (limited to 'if-bsd.c')
-rw-r--r--if-bsd.c7
1 files changed, 6 insertions, 1 deletions
diff --git a/if-bsd.c b/if-bsd.c
index 0db8b304..2b8b9375 100644
--- a/if-bsd.c
+++ b/if-bsd.c
@@ -408,7 +408,10 @@ discover_link(struct interface **ifs, int argc, char * const *argv,
case IFT_ETHER:
ifp->family = ARPHRD_ETHER;
ifp->hwlen = sdl->sdl_alen;
- memcpy(ifp->hwaddr, LLADDR(sdl), sdl->sdl_alen);
+ break;
+ case IFT_IEEE1394:
+ ifp->family = ARPHRD_IEEE1394;
+ ifp->hwlen = sdl->sdl_alen;
break;
case IFT_LOOP:
/* We don't allow loopback unless requested */
@@ -418,6 +421,8 @@ discover_link(struct interface **ifs, int argc, char * const *argv,
}
break;
}
+ if (ifp && ifp->hwlen)
+ memcpy(ifp->hwaddr, LLADDR(sdl), ifp->hwlen);
if (ifl)
ifl->next = ifp;
else