diff options
| author | Donald Sharp <sharpd@cumulusnetworks.com> | 2017-05-26 14:56:19 -0400 |
|---|---|---|
| committer | Donald Sharp <sharpd@cumulusnetworks.com> | 2017-05-26 14:56:19 -0400 |
| commit | 7217de2d8add45e71b49a15df965cc1d26389d5f (patch) | |
| tree | 4fa65b5cee4f2cf4b104c859c36b8bffc28056b4 /babeld/kernel.c | |
| parent | a3d554f27d337283481441902e977968796ca3d9 (diff) | |
babeld: The sockaddr code is not passed through anymore
The hw_addr_len and hw_addr are properly setup on all
the different systems. We no longer need to have
individual daemons know anything about this underlying
mechanism to get the data from the kernel.
Signed-off-by: Donald Sharp <sharpd@cumulusnetworks.com>
Diffstat (limited to 'babeld/kernel.c')
| -rw-r--r-- | babeld/kernel.c | 7 |
1 files changed, 2 insertions, 5 deletions
diff --git a/babeld/kernel.c b/babeld/kernel.c index da8fadac7c..9aaa892b44 100644 --- a/babeld/kernel.c +++ b/babeld/kernel.c @@ -250,13 +250,10 @@ if_eui64(char *ifname, int ifindex, unsigned char *eui) if (ifp == NULL) { return -1; } -#ifdef HAVE_STRUCT_SOCKADDR_DL - u_char len = ifp->sdl.sdl_alen; - char *tmp = ifp->sdl.sdl_data + ifp->sdl.sdl_nlen; -#else + u_char len = (u_char) ifp->hw_addr_len; char *tmp = (void*) ifp->hw_addr; -#endif + if (len == 8) { memcpy(eui, tmp, 8); eui[0] ^= 2; |
