]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Fix from Lionel Ulmer to not have an infinite loop/stack overflow
authorJulian Seward <jseward@acm.org>
Sat, 4 May 2002 19:49:21 +0000 (19:49 +0000)
committerJulian Seward <jseward@acm.org>
Sat, 4 May 2002 19:49:21 +0000 (19:49 +0000)
with sigaction on glibc 2.1.3.

git-svn-id: svn://svn.valgrind.org/valgrind/trunk@214

coregrind/arch/x86-linux/vg_libpthread.c
coregrind/vg_libpthread.c
vg_libpthread.c

index 55846f06a85e8a1f9905eb6e4094599141f4a1fc..f125ea799123807f4ca358e3ad77cafef7c619f2 100644 (file)
@@ -869,11 +869,19 @@ void* (*__libc_internal_tsd_get)
 #include <sys/types.h>
 #include <sys/socket.h>
 
+#ifdef GLIBC_2_1
+extern
+int __sigaction
+             (int signum, 
+              const struct sigaction *act,  
+              struct  sigaction *oldact);
+#else
 extern
 int __libc_sigaction
              (int signum, 
               const struct sigaction *act,  
               struct  sigaction *oldact);
+#endif
 int sigaction(int signum, 
               const struct sigaction *act,  
               struct  sigaction *oldact)
@@ -1415,9 +1423,10 @@ strong_alias(__pthread_key_create, pthread_key_create)
 strong_alias(__pthread_getspecific, pthread_getspecific)
 strong_alias(__pthread_setspecific, pthread_setspecific)
 
-//strong_alias(__sigaction, sigaction)
+#ifndef GLIBC_2_1
 strong_alias(sigaction, __sigaction)
-
+#endif
+     
 strong_alias(close, __close)
 strong_alias(fcntl, __fcntl)
 strong_alias(lseek, __lseek)
index 55846f06a85e8a1f9905eb6e4094599141f4a1fc..f125ea799123807f4ca358e3ad77cafef7c619f2 100644 (file)
@@ -869,11 +869,19 @@ void* (*__libc_internal_tsd_get)
 #include <sys/types.h>
 #include <sys/socket.h>
 
+#ifdef GLIBC_2_1
+extern
+int __sigaction
+             (int signum, 
+              const struct sigaction *act,  
+              struct  sigaction *oldact);
+#else
 extern
 int __libc_sigaction
              (int signum, 
               const struct sigaction *act,  
               struct  sigaction *oldact);
+#endif
 int sigaction(int signum, 
               const struct sigaction *act,  
               struct  sigaction *oldact)
@@ -1415,9 +1423,10 @@ strong_alias(__pthread_key_create, pthread_key_create)
 strong_alias(__pthread_getspecific, pthread_getspecific)
 strong_alias(__pthread_setspecific, pthread_setspecific)
 
-//strong_alias(__sigaction, sigaction)
+#ifndef GLIBC_2_1
 strong_alias(sigaction, __sigaction)
-
+#endif
+     
 strong_alias(close, __close)
 strong_alias(fcntl, __fcntl)
 strong_alias(lseek, __lseek)
index 55846f06a85e8a1f9905eb6e4094599141f4a1fc..f125ea799123807f4ca358e3ad77cafef7c619f2 100644 (file)
@@ -869,11 +869,19 @@ void* (*__libc_internal_tsd_get)
 #include <sys/types.h>
 #include <sys/socket.h>
 
+#ifdef GLIBC_2_1
+extern
+int __sigaction
+             (int signum, 
+              const struct sigaction *act,  
+              struct  sigaction *oldact);
+#else
 extern
 int __libc_sigaction
              (int signum, 
               const struct sigaction *act,  
               struct  sigaction *oldact);
+#endif
 int sigaction(int signum, 
               const struct sigaction *act,  
               struct  sigaction *oldact)
@@ -1415,9 +1423,10 @@ strong_alias(__pthread_key_create, pthread_key_create)
 strong_alias(__pthread_getspecific, pthread_getspecific)
 strong_alias(__pthread_setspecific, pthread_setspecific)
 
-//strong_alias(__sigaction, sigaction)
+#ifndef GLIBC_2_1
 strong_alias(sigaction, __sigaction)
-
+#endif
+     
 strong_alias(close, __close)
 strong_alias(fcntl, __fcntl)
 strong_alias(lseek, __lseek)