sigaltstack - phpMan

Command: man perldoc info search(apropos)  


SIGALTSTACK(2)             Linux Programmer’s Manual            SIGALTSTACK(2)



NAME
       sigaltstack - get or set alternate signal stack content

SYNOPSIS
       #include <signal.h>

       int sigaltstack(const stack_t *ss, stack_t *oss);

       where:

       ss     points  to  a  signalstack  structure defined in <signal.h> containing stack
              content after the call.

       oss    if not NULL, points to a  signalstack  structure  containing  stack  content
              before the call.

DESCRIPTION
       sigaction(2) may indicate that a signal should execute on an alternate stack. Where
       this is the case, sigaltstack(2) stores the signal in an alternate stack  structure
       ss where its execution status may be examined prior to processing.


       The sigaltstack struct is defined in <signal.h> as follows:


                  void       *ss_sp     /* SVID3 uses caddr_t ss_sp
                  int        ss_flags
                  size_t     ss_size
       where:

       ss_sp  points to the stack structure.

       ss_flags
              specifies the stack state to SS_DISABLE or SS_ONSTACK as follows:

              If  ss  is  not NULL,the new state may be set to SS_DISABLE, which specifies
              that the stack is to be disabled and ss_sp  and  ss_size  are  ignored.   If
              SS_DISABLE is not set, the stack will be enabled.

              If  oss is not NULL, the stack state may be either SS_ONSTACK or SS_DISABLE.
              The value SS_ONSTACK indicates that the process is  currently  executing  on
              the  alternate stack and that any attempt to modify it during execution will
              fail.  The value SS_DISABLE indicates that the current signal stack is  dis-
              abled.

       ss_size
              specifies the size of the stack.

       The  value  SIGSTKSZ  defines  the  average number of bytes used when allocating an
       alternate stack area.  The value MINSIGSTKSZ defines the minimum stack size  for  a
       signal  handler.   When  processing  an  alternate  stack size, your program should
       include these values in the stack requirement to plan for the overhead of the oper-
       ating system.

RETURN VALUES
       sigaltstack(2) returns 0 on success and -1 on failure.

ERRORS
       sigaltstack(2) sets  errno for the following conditions:

       EINVAL ss is not a null pointer the ss_flags member pointed to by ss contains flags
              other than SS_DISABLE.

       ENOMEM The size of the alternate stack area is less than MINSIGSTKSZ.

       EPERM  An attempt was made to modify an active stack.

STANDARDS
       This function comforms to: XPG4-UNIX.

SEE ALSO
       getcontext(2), sigaction(2), sigsetjmp(3).



Red Hat Linux 6.1              20 September 1999                SIGALTSTACK(2)

Generated by $Id: phpMan.php,v 4.55 2007/09/05 04:42:51 chedong Exp $ Author: Che Dong
On Apache/1.3.41 (Unix) PHP/5.2.5 mod_perl/1.30 mod_gzip/1.3.26.1a
Under GNU General Public License
2009-01-10 09:42 @38.103.63.58 CrawledBy CCBot/1.0 (+http://www.commoncrawl.org/bot.html)
Valid XHTML 1.0!Valid CSS!