This is the mail archive of the libc-hacker@sources.redhat.com mailing list for the glibc project.

Note that libc-hacker is a closed list. You may look at the archives of this list, but subscription and posting are not open.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[PATCH] Warning fix for tst-tls*


Hi!

Sorry for letting this slip in initially.

2003-04-23  Jakub Jelinek  <jakub at redhat dot com>

	* elf/tst-tls12.c (main): Fix declaration.
	* elf/tst-tls10.c (dummy): Make hidden instead of static.
	* elf/tst-tlsmod7.c (dummy): Likewise.
	* elf/tst-tlsmod8.c (dummy): Likewise.
	* elf/tst-tlsmod9.c (dummy): Likewise.

--- libc/elf/tst-tls12.c.jj	2003-04-17 15:19:01.000000000 -0400
+++ libc/elf/tst-tls12.c	2003-04-22 18:42:00.000000000 -0400
@@ -5,7 +5,8 @@
   if (p->a != S || p->b != S + 1 || p->c != S + 2)	\
     abort ()
 
-int main()
+int
+main (void)
 {
 #ifdef USE_TLS__THREAD
   struct A *p;
--- libc/elf/tst-tlsmod9.c.jj	2003-04-17 15:19:01.000000000 -0400
+++ libc/elf/tst-tlsmod9.c	2003-04-22 18:40:39.000000000 -0400
@@ -1,7 +1,7 @@
 #include "tst-tls10.h"
 
 #ifdef USE_TLS__THREAD
-static __thread int dummy = 12;
+static __thread int dummy __attribute__((visibility ("hidden"))) = 12;
 __thread struct A a1 = { 4, 5, 6 };
 __thread struct A a3 __attribute__((tls_model("initial-exec")))
   = { 10, 11, 12 };
--- libc/elf/tst-tls10.c.jj	2003-04-22 18:39:29.000000000 -0400
+++ libc/elf/tst-tls10.c	2003-04-22 18:39:16.000000000 -0400
@@ -1,7 +1,7 @@
 #include "tst-tls10.h"
 
 #ifdef USE_TLS__THREAD
-static __thread int dummy = 12;
+__thread int dummy __attribute__((visibility ("hidden"))) = 12;
 __thread struct A local = { 1, 2, 3 };
 #endif
 
--- libc/elf/tst-tlsmod7.c.jj	2003-04-17 15:19:01.000000000 -0400
+++ libc/elf/tst-tlsmod7.c	2003-04-22 18:40:03.000000000 -0400
@@ -1,7 +1,7 @@
 #include "tst-tls10.h"
 
 #ifdef USE_TLS__THREAD
-static __thread int dummy = 12;
+__thread int dummy __attribute__((visibility ("hidden"))) = 12;
 __thread struct A a1 = { 4, 5, 6 };
 __thread struct A a2 = { 7, 8, 9 };
 __thread struct A a3 __attribute__((tls_model("initial-exec")))
--- libc/elf/tst-tlsmod8.c.jj	2003-04-17 15:19:01.000000000 -0400
+++ libc/elf/tst-tlsmod8.c	2003-04-22 18:40:27.000000000 -0400
@@ -1,7 +1,7 @@
 #include "tst-tls10.h"
 
 #ifdef USE_TLS__THREAD
-static __thread long long dummy = 12;
+__thread long long dummy __attribute__((visibility ("hidden"))) = 12;
 __thread struct A a2 = { 22, 23, 24 };
 __thread struct A a4 __attribute__((tls_model("initial-exec")))
   = { 25, 26, 27 };

	Jakub


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]