]> git.ipfire.org Git - thirdparty/man-pages.git/blob - man3/pthread_testcancel.3
man*/: ffix (un-bracket tables)
[thirdparty/man-pages.git] / man3 / pthread_testcancel.3
1 '\" t
2 .\" Copyright (c) 2008 Linux Foundation, written by Michael Kerrisk
3 .\" <mtk.manpages@gmail.com>
4 .\"
5 .\" SPDX-License-Identifier: Linux-man-pages-copyleft
6 .\"
7 .TH pthread_testcancel 3 (date) "Linux man-pages (unreleased)"
8 .SH NAME
9 pthread_testcancel \- request delivery of any pending cancelation request
10 .SH LIBRARY
11 POSIX threads library
12 .RI ( libpthread ", " \-lpthread )
13 .SH SYNOPSIS
14 .nf
15 .B #include <pthread.h>
16 .PP
17 .B void pthread_testcancel(void);
18 .fi
19 .SH DESCRIPTION
20 Calling
21 .BR pthread_testcancel ()
22 creates a cancelation point within the calling thread,
23 so that a thread that is otherwise executing code that contains
24 no cancelation points will respond to a cancelation request.
25 .PP
26 If cancelability is disabled (using
27 .BR pthread_setcancelstate (3)),
28 or no cancelation request is pending,
29 then a call to
30 .BR pthread_testcancel ()
31 has no effect.
32 .SH RETURN VALUE
33 This function does not return a value.
34 If the calling thread is canceled as a consequence of a call
35 to this function, then the function does not return.
36 .SH ERRORS
37 This function always succeeds.
38 .SH ATTRIBUTES
39 For an explanation of the terms used in this section, see
40 .BR attributes (7).
41 .TS
42 allbox;
43 lbx lb lb
44 l l l.
45 Interface Attribute Value
46 T{
47 .na
48 .nh
49 .BR pthread_testcancel ()
50 T} Thread safety MT-Safe
51 .TE
52 .sp 1
53 .SH STANDARDS
54 POSIX.1-2008.
55 .SH HISTORY
56 glibc 2.0.
57 POSIX.1-2001.
58 .SH EXAMPLES
59 See
60 .BR pthread_cleanup_push (3).
61 .SH SEE ALSO
62 .BR pthread_cancel (3),
63 .BR pthread_cleanup_push (3),
64 .BR pthread_setcancelstate (3),
65 .BR pthreads (7)