Open System Services System Calls Reference Manual (G06.25+, H06.03+)
pthread_testcancel(2) OSS System Calls Reference Manual
NAME
pthread_testcancel - Requests delivery of a pending cancelation request to the calling thread
LIBRARY
G-series native OSS processes: /G/system/sysnn/zsptsrl
H-series OSS processes: /G/system/zdllnnn/zsptdll
SYNOPSIS
#include <spthread.h>
void pthread_testcancel(void);
DESCRIPTION
This function requests delivery of a pending cancelation request to the calling thread. Thus, cal-
ling this function creates a cancelation point within the calling thread.
The cancelation request is delivered only if a request is pending for the calling thread and the
calling thread’s cancelability state is enabled. (A thread disables delivery of cancelation requests
to itself by calling the pthread_setcancelstate()
function.)
When called within very long loops, this function ensures that a pending cancelation request is
noticed by the calling thread within a reasonable amount of time.
RELATED INFORMATION
Functions: pthread_setcancelstate(2).
STANDARDS CONFORMANCE
This function is an extension to the XPG4 Version 2 specification. Interfaces documented on this
reference page conform to the following industry standards:
• IEEE Std 1003.1c-1995, POSIX System Application Program Interface
The use of the header file spthread.h is an HP exception to the POSIX standard.
5−100 Hewlett-Packard Company 527186-003