diff options
author | Claudio Jeker <claudio@cvs.openbsd.org> | 2011-07-08 01:09:53 +0000 |
---|---|---|
committer | Claudio Jeker <claudio@cvs.openbsd.org> | 2011-07-08 01:09:53 +0000 |
commit | 578f8d9d863edfa8128a6ee30bf317c1856e2136 (patch) | |
tree | caa8f79394abec2d0cf4f3a592cc7da41bfe6544 /sys | |
parent | 8bff98f77d1dae9d9a7cfa5ed02b3678e039b81e (diff) |
Increase sdl_data so that more then IFNAMSIZ bytes are available.
Additionally round the sizeof(struct sockaddr_dl) to a power of 2.
OK guenther@ deraadt@
Diffstat (limited to 'sys')
-rw-r--r-- | sys/net/if_dl.h | 9 |
1 files changed, 5 insertions, 4 deletions
diff --git a/sys/net/if_dl.h b/sys/net/if_dl.h index 005229d5cd5..11b979ec3e4 100644 --- a/sys/net/if_dl.h +++ b/sys/net/if_dl.h @@ -1,4 +1,4 @@ -/* $OpenBSD: if_dl.h,v 1.6 2003/06/02 23:28:12 millert Exp $ */ +/* $OpenBSD: if_dl.h,v 1.7 2011/07/08 01:09:52 claudio Exp $ */ /* $NetBSD: if_dl.h,v 1.8 1995/03/26 20:30:13 jtc Exp $ */ /* @@ -63,9 +63,10 @@ struct sockaddr_dl { u_char sdl_type; /* interface type */ u_char sdl_nlen; /* interface name length, no trailing 0 reqd. */ u_char sdl_alen; /* link level address length */ - u_char sdl_slen; /* link layer selector length */ - char sdl_data[12]; /* minimum work area, can be larger; - contains both if name and ll address */ + u_char sdl_slen; /* link layer selector length, mostly 0 */ + char sdl_data[24]; /* minimum work area, can be larger; + contains both if name and ll address; + big enough for IFNAMSIZ plus 8byte ll addr */ }; #define LLADDR(s) ((caddr_t)((s)->sdl_data + (s)->sdl_nlen)) |