arrfab / rpms / glibc

Forked from rpms/glibc 4 years ago
Clone

Blame SOURCES/glibc-rh1505492-s390-backtrace.patch

147e83
commit 618cebeff82ae775308eb29d7891e22861411e21
147e83
Author: Stefan Liebler <stli@linux.vnet.ibm.com>
147e83
Date:   Thu Nov 13 10:42:31 2014 +0100
147e83
147e83
    S/390: Get rid of warning: the comparision will always evaluate as false.
147e83
147e83
diff --git a/sysdeps/s390/s390-32/backtrace.c b/sysdeps/s390/s390-32/backtrace.c
147e83
index 1dbe37eeb6f6db08..0db076804895e200 100644
147e83
--- a/sysdeps/s390/s390-32/backtrace.c
147e83
+++ b/sysdeps/s390/s390-32/backtrace.c
147e83
@@ -77,10 +77,6 @@ init (void)
147e83
   if (unwind_getip == NULL)
147e83
     unwind_backtrace = NULL;
147e83
 }
147e83
-#else
147e83
-# define unwind_backtrace _Unwind_Backtrace
147e83
-# define unwind_getip _Unwind_GetIP
147e83
-#endif
147e83
 
147e83
 static int
147e83
 __backchain_backtrace (void **array, int size)
147e83
@@ -107,6 +103,10 @@ __backchain_backtrace (void **array, int size)
147e83
 
147e83
   return cnt;
147e83
 }
147e83
+#else
147e83
+# define unwind_backtrace _Unwind_Backtrace
147e83
+# define unwind_getip _Unwind_GetIP
147e83
+#endif
147e83
 
147e83
 static _Unwind_Reason_Code
147e83
 backtrace_helper (struct _Unwind_Context *ctx, void *a)
147e83
@@ -130,9 +130,10 @@ __backtrace (void **array, int size)
147e83
   __libc_once_define (static, once);
147e83
 
147e83
   __libc_once (once, init);
147e83
-#endif
147e83
+
147e83
   if (unwind_backtrace == NULL)
147e83
     return __backchain_backtrace (array, size);
147e83
+#endif
147e83
 
147e83
   if (size >= 1)
147e83
     unwind_backtrace (backtrace_helper, &arg;;
147e83
diff --git a/sysdeps/s390/s390-64/backtrace.c b/sysdeps/s390/s390-64/backtrace.c
147e83
index 562d461f97ad5bca..548d312f3cc05151 100644
147e83
--- a/sysdeps/s390/s390-64/backtrace.c
147e83
+++ b/sysdeps/s390/s390-64/backtrace.c
147e83
@@ -76,12 +76,8 @@ init (void)
147e83
   if (unwind_getip == NULL)
147e83
     unwind_backtrace = NULL;
147e83
 }
147e83
-#else
147e83
-# define unwind_backtrace _Unwind_Backtrace
147e83
-# define unwind_getip _Unwind_GetIP
147e83
-#endif
147e83
 
147e83
-int
147e83
+static int
147e83
 __backchain_backtrace (void **array, int size)
147e83
 {
147e83
   /* We assume that all the code is generated with frame pointers set.  */
147e83
@@ -106,6 +102,10 @@ __backchain_backtrace (void **array, int size)
147e83
 
147e83
   return cnt;
147e83
 }
147e83
+#else
147e83
+# define unwind_backtrace _Unwind_Backtrace
147e83
+# define unwind_getip _Unwind_GetIP
147e83
+#endif
147e83
 
147e83
 static _Unwind_Reason_Code
147e83
 backtrace_helper (struct _Unwind_Context *ctx, void *a)
147e83
@@ -129,9 +129,10 @@ __backtrace (void **array, int size)
147e83
   __libc_once_define (static, once);
147e83
 
147e83
   __libc_once (once, init);
147e83
-#endif
147e83
+
147e83
   if (unwind_backtrace == NULL)
147e83
     return __backchain_backtrace (array, size);
147e83
+#endif
147e83
 
147e83
   if (size >= 1)
147e83
     unwind_backtrace (backtrace_helper, &arg;;