From 7d765b8eee88c84a69da0d88645a9e749a08019b Mon Sep 17 00:00:00 2001 From: David Gwynne Date: Tue, 17 Apr 2007 02:07:06 +0000 Subject: point ifreq in the ioctl path at something, so we can void dereferencing random memory. --- sys/dev/pci/if_vic.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'sys/dev/pci/if_vic.c') diff --git a/sys/dev/pci/if_vic.c b/sys/dev/pci/if_vic.c index 7474ac6f387..a3f2b967a58 100644 --- a/sys/dev/pci/if_vic.c +++ b/sys/dev/pci/if_vic.c @@ -1,4 +1,4 @@ -/* $OpenBSD: if_vic.c,v 1.40 2007/04/14 23:35:35 reyk Exp $ */ +/* $OpenBSD: if_vic.c,v 1.41 2007/04/17 02:07:05 dlg Exp $ */ /* * Copyright (c) 2006 Reyk Floeter @@ -1114,8 +1114,8 @@ int vic_ioctl(struct ifnet *ifp, u_long cmd, caddr_t data) { struct vic_softc *sc = (struct vic_softc *)ifp->if_softc; + struct ifreq *ifr = (struct ifreq *)data; struct ifaddr *ifa; - struct ifreq *ifr; int s, error = 0; s = splnet(); -- cgit v1.2.3