1
0
mirror of https://git.dev.opencascade.org/repos/occt.git synced 2025-04-04 18:06:22 +03:00

0025750: Coding rules - eliminate GCC warning -Wunused-but-set-variable in OSD_signal.cxx for Android build

Move variable aSigInfo to the proper scope.
This commit is contained in:
ibs 2015-05-13 11:59:36 +03:00 committed by bugmaster
parent aad4bc1f7b
commit 7d679df3be

View File

@ -129,11 +129,6 @@ static void Handler (const int theSignal)
perror ("sigaction");
}
siginfo_t * aSigInfo = NULL;
#ifdef SA_SIGINFO
aSigInfo = theSigInfo;
#endif
#if defined(HAVE_PTHREAD_H) && defined(NO_CXX_EXCEPTION)
if (pthread_self() != getOCCThread() || !Standard_ErrorHandler::IsInTryBlock()) {
// use the previous signal handler
@ -143,6 +138,12 @@ static void Handler (const int theSignal)
if (asigacthandler.sa_flags & SA_SIGINFO) {
void (*aCurInfoHandle)(int, siginfo_t *, void *) = asigacthandler.sa_sigaction;
siginfo_t * aSigInfo = NULL;
#ifdef SA_SIGINFO
aSigInfo = theSigInfo;
#endif
if (aSigInfo) {
switch (aSigInfo->si_signo) {
case SIGFPE: