From 71119871616da30a8042bfeeb31b72f08cc1b9fb Mon Sep 17 00:00:00 2001 From: christos Date: Sat, 24 Dec 2005 07:37:18 +0000 Subject: [PATCH] Add a cast to l_addr to avoid wrapping. From Johnny Billquist. --- sys/arch/vax/vax/vm_machdep.c | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/sys/arch/vax/vax/vm_machdep.c b/sys/arch/vax/vax/vm_machdep.c index 8c26699ff37e..04d8f779d00d 100644 --- a/sys/arch/vax/vax/vm_machdep.c +++ b/sys/arch/vax/vax/vm_machdep.c @@ -1,4 +1,4 @@ -/* $NetBSD: vm_machdep.c,v 1.89 2005/12/11 12:19:36 christos Exp $ */ +/* $NetBSD: vm_machdep.c,v 1.90 2005/12/24 07:37:18 christos Exp $ */ /* * Copyright (c) 1994 Ludd, University of Lule}, Sweden. @@ -31,7 +31,7 @@ */ #include -__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.89 2005/12/11 12:19:36 christos Exp $"); +__KERNEL_RCSID(0, "$NetBSD: vm_machdep.c,v 1.90 2005/12/24 07:37:18 christos Exp $"); #include "opt_compat_ultrix.h" #include "opt_multiprocessor.h" @@ -190,7 +190,7 @@ cpu_setfunc(l, func, arg) void *arg; { struct pcb *pcb = &l->l_addr->u_pcb; - struct trapframe *tf = (struct trapframe *)(l->l_addr + USPACE) - 1; + struct trapframe *tf = (struct trapframe *)((u_int)l->l_addr + USPACE) - 1; struct callsframe *cf; extern int sret;