]> git.ipfire.org Git - thirdparty/valgrind.git/commitdiff
Change _pthread_cleanup_push and _pthread_cleanup_pop into no-ops
authorJulian Seward <jseward@acm.org>
Wed, 8 May 2002 14:08:22 +0000 (14:08 +0000)
committerJulian Seward <jseward@acm.org>
Wed, 8 May 2002 14:08:22 +0000 (14:08 +0000)
rather than aborts.

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

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

index d869d533fcae1f2b2805f5db5397476977953e3c..a8665fadf4254b5d6f7ac5d3f07556bae918194a 100644 (file)
@@ -1524,6 +1524,28 @@ void _pthread_cleanup_pop_restore ( void )
       ignored("_pthread_cleanup_pop_restore");
 }
 
+/*--------*/
+void _pthread_cleanup_push (struct _pthread_cleanup_buffer *__buffer,
+                            void (*__routine) (void *),
+                            void *__arg)
+{
+   static int moans = N_MOANS;
+   if (moans-- > 0) 
+      ignored("_pthread_cleanup_push");
+}
+
+void _pthread_cleanup_pop (struct _pthread_cleanup_buffer *__buffer,
+                           int __execute)
+{
+   static int moans = N_MOANS;
+   if (moans-- > 0) {
+      if (__execute)
+         ignored("_pthread_cleanup_pop-EXECUTE");
+      else 
+         ignored("_pthread_cleanup_pop-NO-EXECUTE");
+   }
+}
+
 
 /* This doesn't seem to be needed to simulate libpthread.so's external
    interface, but many people complain about its absence. */
index db9acb35b9234ea7da592cc892e9a146ccae57ff..c592e3215f436c5eb702b92f3c1f3a32b1bc5678 100644 (file)
@@ -75,9 +75,9 @@ void __pwrite64 ( void )  { unimp("__pwrite64"); }
 void __vfork ( void )  { unimp("__vfork"); }
 //void __wait ( void )  { unimp("__wait"); }
 //void __write ( void )  { unimp("__write"); }
-void _pthread_cleanup_pop ( void )  { unimp("_pthread_cleanup_pop"); }
+//void _pthread_cleanup_pop ( void )  { unimp("_pthread_cleanup_pop"); }
 //void _pthread_cleanup_pop_restore ( void )  { unimp("_pthread_cleanup_pop_restore"); }
-void _pthread_cleanup_push ( void )  { unimp("_pthread_cleanup_push"); }
+//void _pthread_cleanup_push ( void )  { unimp("_pthread_cleanup_push"); }
 //void _pthread_cleanup_push_defer ( void )  { unimp("_pthread_cleanup_push_defer"); }
 //void longjmp ( void )  { unimp("longjmp"); }
 //void pthread_atfork ( void )  { unimp("pthread_atfork"); }
index d869d533fcae1f2b2805f5db5397476977953e3c..a8665fadf4254b5d6f7ac5d3f07556bae918194a 100644 (file)
@@ -1524,6 +1524,28 @@ void _pthread_cleanup_pop_restore ( void )
       ignored("_pthread_cleanup_pop_restore");
 }
 
+/*--------*/
+void _pthread_cleanup_push (struct _pthread_cleanup_buffer *__buffer,
+                            void (*__routine) (void *),
+                            void *__arg)
+{
+   static int moans = N_MOANS;
+   if (moans-- > 0) 
+      ignored("_pthread_cleanup_push");
+}
+
+void _pthread_cleanup_pop (struct _pthread_cleanup_buffer *__buffer,
+                           int __execute)
+{
+   static int moans = N_MOANS;
+   if (moans-- > 0) {
+      if (__execute)
+         ignored("_pthread_cleanup_pop-EXECUTE");
+      else 
+         ignored("_pthread_cleanup_pop-NO-EXECUTE");
+   }
+}
+
 
 /* This doesn't seem to be needed to simulate libpthread.so's external
    interface, but many people complain about its absence. */
index db9acb35b9234ea7da592cc892e9a146ccae57ff..c592e3215f436c5eb702b92f3c1f3a32b1bc5678 100644 (file)
@@ -75,9 +75,9 @@ void __pwrite64 ( void )  { unimp("__pwrite64"); }
 void __vfork ( void )  { unimp("__vfork"); }
 //void __wait ( void )  { unimp("__wait"); }
 //void __write ( void )  { unimp("__write"); }
-void _pthread_cleanup_pop ( void )  { unimp("_pthread_cleanup_pop"); }
+//void _pthread_cleanup_pop ( void )  { unimp("_pthread_cleanup_pop"); }
 //void _pthread_cleanup_pop_restore ( void )  { unimp("_pthread_cleanup_pop_restore"); }
-void _pthread_cleanup_push ( void )  { unimp("_pthread_cleanup_push"); }
+//void _pthread_cleanup_push ( void )  { unimp("_pthread_cleanup_push"); }
 //void _pthread_cleanup_push_defer ( void )  { unimp("_pthread_cleanup_push_defer"); }
 //void longjmp ( void )  { unimp("longjmp"); }
 //void pthread_atfork ( void )  { unimp("pthread_atfork"); }
index d869d533fcae1f2b2805f5db5397476977953e3c..a8665fadf4254b5d6f7ac5d3f07556bae918194a 100644 (file)
@@ -1524,6 +1524,28 @@ void _pthread_cleanup_pop_restore ( void )
       ignored("_pthread_cleanup_pop_restore");
 }
 
+/*--------*/
+void _pthread_cleanup_push (struct _pthread_cleanup_buffer *__buffer,
+                            void (*__routine) (void *),
+                            void *__arg)
+{
+   static int moans = N_MOANS;
+   if (moans-- > 0) 
+      ignored("_pthread_cleanup_push");
+}
+
+void _pthread_cleanup_pop (struct _pthread_cleanup_buffer *__buffer,
+                           int __execute)
+{
+   static int moans = N_MOANS;
+   if (moans-- > 0) {
+      if (__execute)
+         ignored("_pthread_cleanup_pop-EXECUTE");
+      else 
+         ignored("_pthread_cleanup_pop-NO-EXECUTE");
+   }
+}
+
 
 /* This doesn't seem to be needed to simulate libpthread.so's external
    interface, but many people complain about its absence. */
index db9acb35b9234ea7da592cc892e9a146ccae57ff..c592e3215f436c5eb702b92f3c1f3a32b1bc5678 100644 (file)
@@ -75,9 +75,9 @@ void __pwrite64 ( void )  { unimp("__pwrite64"); }
 void __vfork ( void )  { unimp("__vfork"); }
 //void __wait ( void )  { unimp("__wait"); }
 //void __write ( void )  { unimp("__write"); }
-void _pthread_cleanup_pop ( void )  { unimp("_pthread_cleanup_pop"); }
+//void _pthread_cleanup_pop ( void )  { unimp("_pthread_cleanup_pop"); }
 //void _pthread_cleanup_pop_restore ( void )  { unimp("_pthread_cleanup_pop_restore"); }
-void _pthread_cleanup_push ( void )  { unimp("_pthread_cleanup_push"); }
+//void _pthread_cleanup_push ( void )  { unimp("_pthread_cleanup_push"); }
 //void _pthread_cleanup_push_defer ( void )  { unimp("_pthread_cleanup_push_defer"); }
 //void longjmp ( void )  { unimp("longjmp"); }
 //void pthread_atfork ( void )  { unimp("pthread_atfork"); }