1RAISE(3)                   Linux Programmer's Manual                  RAISE(3)
2
3
4

NAME

6       raise - send a signal to the caller
7

SYNOPSIS

9       #include <signal.h>
10
11       int raise(int sig);
12

DESCRIPTION

14       The  raise()  function sends a signal to the calling process or thread.
15       In a single-threaded program it is equivalent to
16
17           kill(getpid(), sig);
18
19       In a multithreaded program it is equivalent to
20
21           pthread_kill(pthread_self(), sig);
22
23       If the signal causes a handler to be called, raise() will  return  only
24       after the signal handler has returned.
25

RETURN VALUE

27       raise() returns 0 on success, and nonzero for failure.
28

ATTRIBUTES

30       For   an   explanation   of   the  terms  used  in  this  section,  see
31       attributes(7).
32
33       ┌──────────┬───────────────┬─────────┐
34Interface Attribute     Value   
35       ├──────────┼───────────────┼─────────┤
36raise()   │ Thread safety │ MT-Safe │
37       └──────────┴───────────────┴─────────┘

CONFORMING TO

39       POSIX.1-2001, POSIX.1-2008, C89, C99.
40

NOTES

42       Since version 2.3.3, glibc implements raise() by calling tgkill(2),  if
43       the kernel supports that system call.  Older glibc versions implemented
44       raise() using kill(2).
45

SEE ALSO

47       getpid(2), kill(2), sigaction(2), signal(2), pthread_kill(3), signal(7)
48

COLOPHON

50       This page is part of release 4.15 of the Linux  man-pages  project.   A
51       description  of  the project, information about reporting bugs, and the
52       latest    version    of    this    page,    can     be     found     at
53       https://www.kernel.org/doc/man-pages/.
54
55
56
57GNU                               2015-08-08                          RAISE(3)
Impressum