[PATCH 1/3] Move RTLD_DI_SETSIGNAL code into a separate block to quiet warning

Alan Coopersmith alan.coopersmith at oracle.com
Wed Dec 17 20:50:01 PST 2014


Gets rid of gcc 4.8 warning:
 osinit.c:211:9: warning: ISO C90 forbids mixed declarations and code
  [-Wdeclaration-after-statement]

Signed-off-by: Alan Coopersmith <alan.coopersmith at oracle.com>
---
 os/osinit.c |    6 ++++--
 1 file changed, 4 insertions(+), 2 deletions(-)

diff --git a/os/osinit.c b/os/osinit.c
index ff0979a..91e3e06 100644
--- a/os/osinit.c
+++ b/os/osinit.c
@@ -208,9 +208,11 @@ OsInit(void)
          * for failures to load libraries/modules at runtime so we can clean up
          * after ourselves.
          */
-        int failure_signal = SIGQUIT;
+        {
+            int failure_signal = SIGQUIT;
 
-        dlinfo(RTLD_SELF, RTLD_DI_SETSIGNAL, &failure_signal);
+            dlinfo(RTLD_SELF, RTLD_DI_SETSIGNAL, &failure_signal);
+        }
 #endif
 
 #if !defined(XQUARTZ)    /* STDIN is already /dev/null and STDOUT/STDERR is managed by console_redirect.c */
-- 
1.7.9.2



More information about the xorg-devel mailing list