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-14 17:43:49 +03:00
committed by bugmaster
parent aad4bc1f7b
commit 7d679df3be
+6 -5
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: