aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorGaius Mulley <gaius.mulley@southwales.ac.uk>2022-04-29 11:03:08 +0100
committerGaius Mulley <gaius.mulley@southwales.ac.uk>2022-04-29 11:03:08 +0100
commitcf78131316dc9abbcbb6477233d84c23b01888d7 (patch)
tree28678336516bd4636c2493d26e24ff726cee7b3b
parentf3673984ea20937d1057f1d92841c88fdcd1e9be (diff)
downloadgcc-cf78131316dc9abbcbb6477233d84c23b01888d7.zip
gcc-cf78131316dc9abbcbb6477233d84c23b01888d7.tar.gz
gcc-cf78131316dc9abbcbb6477233d84c23b01888d7.tar.bz2
PR-105390 BugFix - change handbuilt SysExceptions to avoid the name sigfpe.
2022-04-29 Gaius Mulley <gaius.mulley@southwales.ac.uk> gcc/m2/ChangeLog: * m2/gm2-libs-ch/SysExceptions.c: Replace sigfpe with sigfpe_ to avoid name clash with C signal infastructure. * m2/mc-boot-ch/GSysExceptions.c: Replace sigfpe with sigfpe_ to avoid name clash with C signal infastructure. Signed-off-by: Gaius Mulley <gaius.mulley@southwales.ac.uk>
-rw-r--r--gcc/m2/gm2-libs-ch/SysExceptions.c10
-rw-r--r--gcc/m2/mc-boot-ch/GSysExceptions.c10
2 files changed, 10 insertions, 10 deletions
diff --git a/gcc/m2/gm2-libs-ch/SysExceptions.c b/gcc/m2/gm2-libs-ch/SysExceptions.c
index b21f129..1760fd2 100644
--- a/gcc/m2/gm2-libs-ch/SysExceptions.c
+++ b/gcc/m2/gm2-libs-ch/SysExceptions.c
@@ -93,7 +93,7 @@ extern "C" {
#if defined(HAVE_SIGNAL_H)
static struct sigaction sigbus;
-static struct sigaction sigfpe;
+static struct sigaction sigfpe_;
static struct sigaction sigsegv;
static void (*indexProc) (void *);
@@ -206,11 +206,11 @@ SysExceptions_InitExceptionHandlers (
if (sigaction (SIGSEGV, &sigsegv, &old) != 0)
perror ("unable to install the sigsegv signal handler");
- sigfpe.sa_sigaction = sigfpeDespatcher;
- sigfpe.sa_flags = (SA_SIGINFO);
- sigemptyset (&sigfpe.sa_mask);
+ sigfpe_.sa_sigaction = sigfpeDespatcher;
+ sigfpe_.sa_flags = (SA_SIGINFO);
+ sigemptyset (&sigfpe_.sa_mask);
- if (sigaction (SIGFPE, &sigfpe, &old) != 0)
+ if (sigaction (SIGFPE, &sigfpe_, &old) != 0)
perror ("unable to install the sigfpe signal handler");
}
diff --git a/gcc/m2/mc-boot-ch/GSysExceptions.c b/gcc/m2/mc-boot-ch/GSysExceptions.c
index c7c285c..f6cddf9 100644
--- a/gcc/m2/mc-boot-ch/GSysExceptions.c
+++ b/gcc/m2/mc-boot-ch/GSysExceptions.c
@@ -86,7 +86,7 @@ along with GNU Modula-2; see the file COPYING3. If not see
#if defined(HAVE_SIGNAL_H)
static struct sigaction sigbus;
-static struct sigaction sigfpe;
+static struct sigaction sigfpe_;
static struct sigaction sigsegv;
static void (*indexProc) (void *);
@@ -200,11 +200,11 @@ SysExceptions_InitExceptionHandlers (
if (sigaction (SIGSEGV, &sigsegv, &old) != 0)
perror ("unable to install the sigsegv signal handler");
- sigfpe.sa_sigaction = sigfpeDespatcher;
- sigfpe.sa_flags = (SA_SIGINFO);
- sigemptyset (&sigfpe.sa_mask);
+ sigfpe_.sa_sigaction = sigfpeDespatcher;
+ sigfpe_.sa_flags = (SA_SIGINFO);
+ sigemptyset (&sigfpe_.sa_mask);
- if (sigaction (SIGFPE, &sigfpe, &old) != 0)
+ if (sigaction (SIGFPE, &sigfpe_, &old) != 0)
perror ("unable to install the sigfpe signal handler");
}