summaryrefslogtreecommitdiffstats
path: root/tests/bugs/bug-1058663.c
diff options
context:
space:
mode:
Diffstat (limited to 'tests/bugs/bug-1058663.c')
-rw-r--r--tests/bugs/bug-1058663.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/tests/bugs/bug-1058663.c b/tests/bugs/bug-1058663.c
index 631afecce1f..8f26d0f07c8 100644
--- a/tests/bugs/bug-1058663.c
+++ b/tests/bugs/bug-1058663.c
@@ -73,6 +73,10 @@ int read_after_eof(char *filename)
void catch_sigbus(int signum)
{
switch (signum) {
+#ifdef __NetBSD__
+ /* Depending on architecture, we can get SIGSEGV */
+ case SIGSEGV: /* FALLTHROUGH */
+#endif
case SIGBUS:
sigbus_received++;
if (!expect_sigbus)
@@ -94,6 +98,10 @@ int main(int argc, char** argv)
return EXIT_FAILURE;
}
+#ifdef __NetBSD__
+ /* Depending on architecture, we can get SIGSEGV */
+ signal(SIGSEGV, catch_sigbus);
+#endif
signal(SIGBUS, catch_sigbus);
/* the next test should not trigger SIGBUS */