close_range.2: Minor wording fix
[man-pages.git] / man2 / sgetmask.2
blob336d7cb695bbf76d327fef21d01f4dfa5bb2d697
1 .\" Copyright (c) 2007 by Michael Kerrisk <mtk.manpages@gmail.com>
2 .\"
3 .\" %%%LICENSE_START(VERBATIM)
4 .\" Permission is granted to make and distribute verbatim copies of this
5 .\" manual provided the copyright notice and this permission notice are
6 .\" preserved on all copies.
7 .\"
8 .\" Permission is granted to copy and distribute modified versions of this
9 .\" manual under the conditions for verbatim copying, provided that the
10 .\" entire resulting derived work is distributed under the terms of a
11 .\" permission notice identical to this one.
12 .\"
13 .\" Since the Linux kernel and libraries are constantly changing, this
14 .\" manual page may be incorrect or out-of-date.  The author(s) assume no
15 .\" responsibility for errors or omissions, or for damages resulting from
16 .\" the use of the information contained herein.  The author(s) may not
17 .\" have taken the same level of care in the production of this manual,
18 .\" which is licensed free of charge, as they might when working
19 .\" professionally.
20 .\"
21 .\" Formatted or processed versions of this manual, if unaccompanied by
22 .\" the source, must acknowledge the copyright and authors of this work.
23 .\" %%%LICENSE_END
24 .\"
25 .TH SGETMASK 2  2020-08-13 "Linux" "Linux Programmer's Manual"
26 .SH NAME
27 sgetmask, ssetmask \- manipulation of signal mask (obsolete)
28 .SH SYNOPSIS
29 .nf
30 .B "long sgetmask(void);"
31 .BI "long ssetmask(long " newmask );
32 .fi
33 .PP
34 .IR Note :
35 There are no glibc wrappers for these system calls; see NOTES.
36 .SH DESCRIPTION
37 These system calls are obsolete.
38 .IR "Do not use them" ;
39 use
40 .BR sigprocmask (2)
41 instead.
42 .PP
43 .BR sgetmask ()
44 returns the signal mask of the calling process.
45 .PP
46 .BR ssetmask ()
47 sets the signal mask of the calling process to the value given in
48 .IR newmask .
49 The previous signal mask is returned.
50 .PP
51 The signal masks dealt with by these two system calls
52 are plain bit masks (unlike the
53 .I sigset_t
54 used by
55 .BR sigprocmask (2));
56 use
57 .BR sigmask (3)
58 to create and inspect these masks.
59 .SH RETURN VALUE
60 .BR sgetmask ()
61 always successfully returns the signal mask.
62 .BR ssetmask ()
63 always succeeds, and returns the previous signal mask.
64 .SH ERRORS
65 These system calls always succeed.
66 .SH VERSIONS
67 Since Linux 3.16,
68 .\" f6187769dae48234f3877df3c4d99294cc2254fa
69 support for these system calls is optional,
70 depending on whether the kernel was built with the
71 .B CONFIG_SGETMASK_SYSCALL
72 option.
73 .SH CONFORMING TO
74 These system calls are Linux-specific.
75 .SH NOTES
76 Glibc does not provide wrappers for these obsolete system calls;
77 in the unlikely event that you want to call them, use
78 .BR syscall (2).
79 .PP
80 These system calls are unaware of signal numbers greater than 31
81 (i.e., real-time signals).
82 .PP
83 These system calls do not exist on x86-64.
84 .PP
85 It is not possible to block
86 .B SIGSTOP
88 .BR SIGKILL .
89 .SH SEE ALSO
90 .BR sigprocmask (2),
91 .BR signal (7)