]> git.ipfire.org Git - thirdparty/man-pages.git/blobdiff - man3/gsignal.3
fanotify_init.2, fanotify.7: Document FAN_REPORT_TID
[thirdparty/man-pages.git] / man3 / gsignal.3
index db5165585d86b896d84f451b90e56298e4421f32..2e59767f8b74cf962058ba23753d4f24a978a59e 100644 (file)
@@ -1,5 +1,6 @@
 .\" Copyright (C) 2002 Andries Brouwer <aeb@cwi.nl>
 .\"
+.\" %%%LICENSE_START(VERBATIM)
 .\" Permission is granted to make and distribute verbatim copies of this
 .\" manual provided the copyright notice and this permission notice are
 .\" preserved on all copies.
 .\"
 .\" Formatted or processed versions of this manual, if unaccompanied by
 .\" the source, must acknowledge the copyright and authors of this work.
+.\" %%%LICENSE_END
 .\"
 .\" This replaces an earlier man page written by Walter Harms
 .\" <walter.harms@informatik.uni-oldenburg.de>.
-.TH GSIGNAL 3  2002-08-25 "" "Linux Programmer's Manual"
+.TH GSIGNAL 3  2017-09-15 "" "Linux Programmer's Manual"
 .SH NAME
 gsignal, ssignal \- software signal facility
 .SH SYNOPSIS
 .nf
 .B #include <signal.h>
-.sp
+.PP
 .B typedef void (*sighandler_t)(int);
-.sp
-.BI "int gsignal(" signum );
-.sp
+.PP
+.BI "int gsignal(int " signum );
+.PP
 .BI "sighandler_t ssignal(int " signum ", sighandler_t " action );
+.fi
+.PP
+.in -4n
+Feature Test Macro Requirements for glibc (see
+.BR feature_test_macros (7)):
+.in
+.PP
+.BR gsignal (),
+.BR ssignal ():
+    Since glibc 2.19:
+        _DEFAULT_SOURCE
+    Glibc 2.19 and earlier:
+        _SVID_SOURCE
 .SH DESCRIPTION
 Don't use these functions under Linux.
 Due to a historical mistake, under Linux these functions are
@@ -42,10 +57,13 @@ aliases for
 and
 .BR signal (2),
 respectively.
-.LP
+.PP
 Elsewhere, on System V-like systems, these functions implement
 software signaling, entirely independent of the classical
-signal and kill functions.
+.BR signal (2)
+and
+.BR kill (2)
+functions.
 The function
 .BR ssignal ()
 defines the action to take when the software signal with
@@ -53,24 +71,47 @@ number
 .I signum
 is raised using the function
 .BR gsignal (),
-and returns the previous such action or SIG_DFL.
+and returns the previous such action or
+.BR SIG_DFL .
 The function
 .BR gsignal ()
-does the following: if no action (or the action SIG_DFL) was
+does the following: if no action (or the action
+.BR SIG_DFL )
+was
 specified for
 .IR signum ,
 then it does nothing and returns 0.
-If the action SIG_IGN was specified for
+If the action
+.B SIG_IGN
+was specified for
 .IR signum ,
 then it does nothing and returns 1.
-Otherwise, it resets the action to SIG_DFL and calls
-the action function with parameter
+Otherwise, it resets the action to
+.B SIG_DFL
+and calls
+the action function with argument
 .IR signum ,
 and returns the value returned by that function.
 The range of possible values
 .I signum
-varies (often 1-15 or 1-17).
-.SH "CONFORMING TO"
+varies (often 1\(en15 or 1\(en17).
+.SH ATTRIBUTES
+For an explanation of the terms used in this section, see
+.BR attributes (7).
+.TS
+allbox;
+lb lb lb
+l l l.
+Interface      Attribute       Value
+T{
+.BR gsignal ()
+T}     Thread safety   MT-Safe
+T{
+.BR ssignal ()
+T}     Thread safety   MT-Safe sigintr
+.TE
+.sp 1
+.SH CONFORMING TO
 These functions are available under AIX, DG/UX, HP-UX, SCO, Solaris, Tru64.
 They are called obsolete under most of these systems, and are
 broken under Linux libc and glibc.
@@ -78,7 +119,7 @@ Some systems also have
 .BR gsignal_r ()
 and
 .BR ssignal_r ().
-.SH "SEE ALSO"
+.SH SEE ALSO
 .BR kill (2),
 .BR signal (2),
 .BR raise (3)