Source-Changes-HG archive
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index][Old Index]
[src/trunk]: src/sys/arch/m68k/include The __fgetenv() macro operates on a fe...
details: https://anonhg.NetBSD.org/src/rev/6a1f5aba2fa2
branches: trunk
changeset: 356263:6a1f5aba2fa2
user: phx <phx%NetBSD.org@localhost>
date: Wed Sep 13 09:55:35 2017 +0000
description:
The __fgetenv() macro operates on a fenv_t, not on a fenv_t *.
Fixes a segfault in fegetenv() and feholdexcept().
diffstat:
sys/arch/m68k/include/fenv.h | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
diffs (27 lines):
diff -r aabeb0b8365b -r 6a1f5aba2fa2 sys/arch/m68k/include/fenv.h
--- a/sys/arch/m68k/include/fenv.h Wed Sep 13 08:26:38 2017 +0000
+++ b/sys/arch/m68k/include/fenv.h Wed Sep 13 09:55:35 2017 +0000
@@ -1,4 +1,4 @@
-/* $NetBSD: fenv.h,v 1.6 2017/03/22 23:11:09 chs Exp $ */
+/* $NetBSD: fenv.h,v 1.7 2017/09/13 09:55:35 phx Exp $ */
/*-
* Copyright (c) 2015 The NetBSD Foundation, Inc.
@@ -210,7 +210,7 @@
__fenv_static inline int
fegetenv(fenv_t *__envp)
{
- __fgetenv(__envp);
+ __fgetenv(*__envp);
return 0;
}
@@ -220,7 +220,7 @@
{
fexcept_t __fpcr, __fpsr;
- __fgetenv(__envp);
+ __fgetenv(*__envp);
__fpsr = __envp->fpsr & ~FE_ALL_EXCEPT;
__set_fpsr(__fpsr); /* clear all */
__fpcr = __envp->fpcr & ~(FE_ALL_EXCEPT << 6);
Home |
Main Index |
Thread Index |
Old Index