summaryrefslogtreecommitdiff
path: root/usr/src/man/man3ucb/siginterrupt.3ucb
diff options
context:
space:
mode:
Diffstat (limited to 'usr/src/man/man3ucb/siginterrupt.3ucb')
-rw-r--r--usr/src/man/man3ucb/siginterrupt.3ucb69
1 files changed, 69 insertions, 0 deletions
diff --git a/usr/src/man/man3ucb/siginterrupt.3ucb b/usr/src/man/man3ucb/siginterrupt.3ucb
new file mode 100644
index 0000000000..ffd5f7c09a
--- /dev/null
+++ b/usr/src/man/man3ucb/siginterrupt.3ucb
@@ -0,0 +1,69 @@
+'\" te
+.\" Copyright (c) 2007, Sun Microsystems, Inc. All Rights Reserved.
+.\" Copyright (c) 1985 Regents of the University of California. All rights reserved. The Berkeley software License Agreement specifies the terms and conditions for redistribution.
+.TH siginterrupt 3UCB "30 Oct 2007" "SunOS 5.11" "SunOS/BSD Compatibility Library Functions"
+.SH NAME
+siginterrupt \- allow signals to interrupt functions
+.SH SYNOPSIS
+.LP
+.nf
+\fB/usr/ucb/cc\fR [ \fIflag\fR ... ] \fIfile\fR ...
+
+\fBint\fR \fBsiginterrupt\fR(\fIsig\fR, \fIflag\fR)
+\fBint\fR \fIsig\fR, \fIflag\fR;
+.fi
+
+.SH DESCRIPTION
+.sp
+.LP
+\fBsiginterrupt()\fR is used to change the function restart behavior when a
+function is interrupted by the specified signal. If the flag is false
+(\fB0\fR), then functions will be restarted if they are interrupted by the
+specified signal and no data has been transferred yet. System call restart is
+the default behavior when the \fBsignal\fR(3C) routine is used.
+.sp
+.LP
+If the flag is true, (\fB1\fR), then restarting of functions is disabled. If
+a function is interrupted by the specified signal and no data has been
+transferred, the function will return \fB\(mi1\fR with \fBerrno\fR set to
+\fBEINTR\fR. Interrupted functions that have started transferring data will
+return the amount of data actually transferred.
+.sp
+.LP
+Issuing a \fBsiginterrupt()\fR call during the execution of a signal handler
+will cause the new action to take place on the next signal to be caught.
+.SH RETURN VALUES
+.sp
+.LP
+A \fB0\fR value indicates that the call succeeded. A \fB\(mi1\fR value
+indicates that the call failed and \fBerrno\fR is set to indicate the error.
+.SH ERRORS
+.sp
+.LP
+\fBsiginterrupt()\fR may return the following error:
+.sp
+.ne 2
+.mk
+.na
+\fB\fBEINVAL\fR\fR
+.ad
+.RS 10n
+.rt
+\fIsig\fR is not a valid signal.
+.RE
+
+.SH SEE ALSO
+.sp
+.LP
+\fBsigblock\fR(3UCB), \fBsigvec\fR(3UCB), \fBsignal\fR(3C)
+.SH NOTES
+.sp
+.LP
+Use of these interfaces should be restricted to only applications written on
+BSD platforms. Use of these interfaces with any of the system libraries or in
+multi-threaded applications is unsupported.
+.sp
+.LP
+This library routine uses an extension of the \fBsigvec\fR(3UCB) function that
+is not available in 4.2 BSD, hence it should not be used if backward
+compatibility is needed.