From 49978a644d7c5f8f94165edba0313f1b58ff60fe Mon Sep 17 00:00:00 2001 From: Miod Vallat Date: Wed, 9 May 2012 21:25:34 +0000 Subject: Do not include and pollute userland namespace with struct reg in . --- sys/arch/m88k/include/signal.h | 5 ++--- sys/arch/m88k/m88k/sig_machdep.c | 5 +++-- 2 files changed, 5 insertions(+), 5 deletions(-) (limited to 'sys/arch/m88k') diff --git a/sys/arch/m88k/include/signal.h b/sys/arch/m88k/include/signal.h index ef4dfed462b..2303835c934 100644 --- a/sys/arch/m88k/include/signal.h +++ b/sys/arch/m88k/include/signal.h @@ -1,4 +1,4 @@ -/* $OpenBSD: signal.h,v 1.5 2011/03/23 16:54:35 pirofti Exp $ */ +/* $OpenBSD: signal.h,v 1.6 2012/05/09 21:25:33 miod Exp $ */ /* * Copyright (c) 1996 Nivas Madhur * All rights reserved. @@ -38,7 +38,6 @@ typedef int sig_atomic_t; #if __BSD_VISIBLE || __XPG_VISIBLE >= 420 -#include /* * Information pushed on stack when a signal is delivered. @@ -53,7 +52,7 @@ struct sigcontext { int sc_onstack; /* sigstack state to restore */ int sc_mask; /* signal mask to restore */ /* begin machine dependent portion */ - struct reg sc_regs; + unsigned int sc_regs[32 + 25]; }; #endif /* __BSD_VISIBLE || __XPG_VISIBLE >= 420 */ #endif /* _M88K_SIGNAL_H_ */ diff --git a/sys/arch/m88k/m88k/sig_machdep.c b/sys/arch/m88k/m88k/sig_machdep.c index 4e3e88b2f91..7841cec5ad3 100644 --- a/sys/arch/m88k/m88k/sig_machdep.c +++ b/sys/arch/m88k/m88k/sig_machdep.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sig_machdep.c,v 1.13 2011/07/05 04:48:01 guenther Exp $ */ +/* $OpenBSD: sig_machdep.c,v 1.14 2012/05/09 21:25:33 miod Exp $ */ /* * Copyright (c) 1998, 1999, 2000, 2001 Steve Murphree, Jr. * Copyright (c) 1996 Nivas Madhur @@ -212,7 +212,8 @@ sys_sigreturn(struct proc *p, void *v, register_t *retval) tf = p->p_md.md_tf; scp = &ksc; - if ((scp->sc_regs.epsr ^ tf->tf_regs.epsr) & PSR_USERSTATIC) + if ((((struct reg *)&scp->sc_regs)->epsr ^ tf->tf_regs.epsr) & + PSR_USERSTATIC) return (EINVAL); bcopy((const void *)&scp->sc_regs, (caddr_t)&tf->tf_regs, -- cgit v1.2.3