Date: Tue, 23 Nov 1999 14:13:12 +0800 From: Peter Wemm <peter@netplex.com.au> To: Brian Fundakowski Feldman <green@FreeBSD.org> Cc: Christopher Masto <chris@netmonger.net>, "Daniel O'Connor" <doconnor@gsoft.com.au>, Steve Kargl <sgk@troutmask.apl.washington.edu>, current@FreeBSD.org, Jean-Marc Zucconi <jmz@FreeBSD.org>, "Alexander N. Kabaev" <ak03@gte.com> Subject: Re: Netscape and -current Message-ID: <19991123061312.248461C6D@overcee.netplex.com.au> In-Reply-To: Message from Brian Fundakowski Feldman <green@FreeBSD.org> of "Tue, 23 Nov 1999 00:30:44 EST." <Pine.BSF.4.10.9911230027330.22643-100000@org.dyndns.org>
next in thread | previous in thread | raw e-mail | index | archive | help
Brian Fundakowski Feldman wrote: > Forget anything I said about KAME being the strong possibility :) As > soon as peter noted what commit it could have to do with, I figured > it out and fixed it; after testing, I committed it. Be happy :) Your fix suffers from exactly the same problem.. Suppose down the track that ucontext_t becomes smaller than 'struct sigocontext' ? You're then failing what would have worked. The check against sizeof osigcontext should not be fatal. Index: machdep.c =================================================================== RCS file: /home/ncvs/src/sys/i386/i386/machdep.c,v retrieving revision 1.378 diff -u -r1.378 machdep.c --- machdep.c 1999/11/23 04:09:13 1.378 +++ machdep.c 1999/11/23 05:49:46 @@ -871,14 +871,16 @@ { struct trapframe *regs; ucontext_t *ucp; + struct osigcontext *scp; int cs, eflags; ucp = uap->sigcntxp; + scp = (struct osigcontext *)ucp; - if (!useracc((caddr_t)ucp, sizeof(struct osigcontext), VM_PROT_READ)) - return (EFAULT); - if (((struct osigcontext *)ucp)->sc_trapno == 0x01d516) - return (osigreturn(p, (struct osigreturn_args *)uap)); + if (useracc((caddr_t)scp, sizeof (struct osigcontext), VM_PROT_READ)) { + if (scp->sc_trapno == 0x01d516) + return osigreturn(p, (struct osigreturn_args *)uap); + } /* * Since ucp is not an osigcontext but a ucontext_t, we have to Cheers, -Peter -- Peter Wemm - peter@FreeBSD.org; peter@yahoo-inc.com; peter@netplex.com.au To Unsubscribe: send mail to majordomo@FreeBSD.org with "unsubscribe freebsd-current" in the body of the message
Want to link to this message? Use this URL: <https://mail-archive.FreeBSD.org/cgi/mid.cgi?19991123061312.248461C6D>