From f695be9e48c86553678b151ad753bd908726bf62 Mon Sep 17 00:00:00 2001 From: brad Date: Tue, 20 Jan 2015 04:46:11 +0000 Subject: [PATCH] Fix size of the bcopy when extracting the MAC address. From FreeBSD --- sys/dev/ic/re.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/sys/dev/ic/re.c b/sys/dev/ic/re.c index b296281a9e1..2e5e17f8182 100644 --- a/sys/dev/ic/re.c +++ b/sys/dev/ic/re.c @@ -1,4 +1,4 @@ -/* $OpenBSD: re.c,v 1.170 2015/01/20 04:33:06 brad Exp $ */ +/* $OpenBSD: re.c,v 1.171 2015/01/20 04:46:11 brad Exp $ */ /* $FreeBSD: if_re.c,v 1.31 2004/09/04 07:54:05 ru Exp $ */ /* * Copyright (c) 1997, 1998-2003 @@ -873,7 +873,7 @@ re_attach(struct rl_softc *sc, const char *intrstr) re_read_eeprom(sc, (caddr_t)as, RL_EE_EADDR, 3); for (i = 0; i < ETHER_ADDR_LEN / 2; i++) as[i] = letoh16(as[i]); - bcopy(as, eaddr, sizeof(eaddr)); + bcopy(as, eaddr, ETHER_ADDR_LEN); #ifdef __armish__ /* -- 2.20.1