summaryrefslogtreecommitdiff
path: root/src/fenv/fesetexceptflag.c
diff options
context:
space:
mode:
authorJakob Kaivo <jkk@ung.org>2024-01-31 14:48:09 -0500
committerJakob Kaivo <jkk@ung.org>2024-01-31 14:48:09 -0500
commit78033913abfce71b1bcc075ed188c6b6ec087a13 (patch)
tree2ab38bf89ea46f651c68963c033dac5f345f1e04 /src/fenv/fesetexceptflag.c
parent24e5f210091ce984b47fd510217f10245f800f52 (diff)
add checks for valid exception masks
Diffstat (limited to 'src/fenv/fesetexceptflag.c')
-rw-r--r--src/fenv/fesetexceptflag.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/fenv/fesetexceptflag.c b/src/fenv/fesetexceptflag.c
index d40c7d8c..55f5b1a1 100644
--- a/src/fenv/fesetexceptflag.c
+++ b/src/fenv/fesetexceptflag.c
@@ -1,13 +1,17 @@
#include <fenv.h>
-#include "_safety.h"
+#include "_fenv.h"
int fesetexceptflag(const fexcept_t *flagp, int excepts)
{
SIGNAL_SAFE(0);
+ ASSERT_PREVIOUS_FEXCEPT(flagp, excepts);
+ ASSERT_VALID_EXCEPTION_MASK(excepts);
(void)flagp; (void)excepts;
return 0;
}
+CHECK_2(int, 0, fesetexceptflag, const fexcept_t *, int)
+
/*
The fesetexceptflag function sets the floating-point status flags indicated by the
argument excepts to the states stored in the object pointed to by flagp. The value of