about summary refs log tree commit diff
path: root/nptl/libc-cancellation.c
diff options
context:
space:
mode:
Diffstat (limited to 'nptl/libc-cancellation.c')
-rw-r--r--nptl/libc-cancellation.c9
1 files changed, 9 insertions, 0 deletions
diff --git a/nptl/libc-cancellation.c b/nptl/libc-cancellation.c
index 72a6d108fd..a68ee71450 100644
--- a/nptl/libc-cancellation.c
+++ b/nptl/libc-cancellation.c
@@ -21,6 +21,7 @@
 #include <stdlib.h>
 #include "pthreadP.h"
 #include "atomic.h"
+#include <bits/libc-lock.h>
 
 
 #ifndef NOT_IN_libc
@@ -103,4 +104,12 @@ __libc_disable_asynccancel (int oldtype)
     }
 }
 
+
+void
+__libc_cleanup_routine (struct __pthread_cleanup_frame *f)
+{
+  if (f->__do_it)
+    f->__cancel_routine (f->__cancel_arg);
+}
+
 #endif