Skip to content

Commit 29b8692

Browse files
matthew-reynoldsRichard Earnshaw
authored andcommitted
Fix ARM fegetexceptflag.c
The ARM fegetexceptflag() implementation was accidentally replaced with fesetexceptflag() during refactoring in b7a6e02. Restore the original implementation. Tested on Cortex-M7.
1 parent 60c6716 commit 29b8692

1 file changed

Lines changed: 1 addition & 3 deletions

File tree

newlib/libm/machine/arm/fegetexceptflag.c

Lines changed: 1 addition & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -37,9 +37,7 @@ int fegetexceptflag(fexcept_t *flagp, int excepts)
3737
fexcept_t __fpsr;
3838

3939
vmrs_fpscr(__fpsr);
40-
__fpsr &= ~excepts;
41-
__fpsr |= *flagp & excepts;
42-
vmsr_fpscr(__fpsr);
40+
*flagp = __fpsr & excepts;
4341
#endif
4442
return (0);
4543
}

0 commit comments

Comments
 (0)