1.1 --- /dev/null Thu Jan 01 00:00:00 1970 +0000
1.2 +++ b/os/ossrv/genericopenlibs/cstdlib/LINCSYS/SIGNAL.H Fri Jun 15 03:10:57 2012 +0200
1.3 @@ -0,0 +1,87 @@
1.4 +/*
1.5 +* Copyright (c) 1997-2009 Nokia Corporation and/or its subsidiary(-ies).
1.6 +* All rights reserved.
1.7 +* This component and the accompanying materials are made available
1.8 +* under the terms of "Eclipse Public License v1.0"
1.9 +* which accompanies this distribution, and is available
1.10 +* at the URL "http://www.eclipse.org/legal/epl-v10.html".
1.11 +*
1.12 +* Initial Contributors:
1.13 +* Nokia Corporation - initial contribution.
1.14 +*
1.15 +* Contributors:
1.16 +*
1.17 +* Description:
1.18 +*
1.19 +*/
1.20 +
1.21 +
1.22 +
1.23 +/**
1.24 + @file
1.25 + @publishedAll
1.26 + @released
1.27 +*/
1.28 +
1.29 +#ifndef _SYS_SIGNAL_H
1.30 +#define _SYS_SIGNAL_H
1.31 +
1.32 +#ifndef _STRICT_ANSI
1.33 +
1.34 +typedef unsigned long sigset_t;
1.35 +
1.36 +struct sigaction
1.37 +{
1.38 + void (*sa_handler)();
1.39 + sigset_t sa_mask;
1.40 + int sa_flags;
1.41 +};
1.42 +
1.43 +#define SA_NOCLDSTOP 1 /* only value supported now for sa_flags */
1.44 +#define SIG_SETMASK 0 /* set mask with sigprocmask() */
1.45 +#define SIG_BLOCK 1 /* set of signals to block */
1.46 +#define SIG_UNBLOCK 2 /* set of signals to, well, unblock */
1.47 +
1.48 +
1.49 +/**
1.50 +These depend upon the type of sigset_t, which right now
1.51 +is always a long.. They're in the POSIX namespace, but
1.52 +are not ANSI.
1.53 +*/
1.54 +#define sigaddset(what,sig) (*(what) |= (1<<(sig)))
1.55 +#define sigemptyset(what) (*(what) = 0)
1.56 +
1.57 +int sigprocmask (int how, const sigset_t *a, sigset_t *b);
1.58 +#endif /* _STRICT_ANSI */
1.59 +
1.60 +
1.61 +#define SIGHUP 1 /* hangup */
1.62 +#define SIGINT 2 /* interrupt */
1.63 +#define SIGQUIT 3 /* quit */
1.64 +#define SIGILL 4 /* illegal instruction (not reset when caught) */
1.65 +#define SIGTRAP 5 /* trace trap (not reset when caught) */
1.66 +#define SIGIOT 6 /* IOT instruction */
1.67 +#define SIGABRT 6 /* used by abort, replace SIGIOT in the future */
1.68 +#define SIGEMT 7 /* EMT instruction */
1.69 +#define SIGFPE 8 /* floating point exception */
1.70 +#define SIGKILL 9 /* kill (cannot be caught or ignored) */
1.71 +#define SIGBUS 10 /* bus error */
1.72 +#define SIGSEGV 11 /* segmentation violation */
1.73 +#define SIGSYS 12 /* bad argument to system call */
1.74 +#define SIGPIPE 13 /* write on a pipe with no one to read it */
1.75 +#define SIGALRM 14 /* alarm clock */
1.76 +#define SIGTERM 15 /* software termination signal from kill */
1.77 +#define SIGUSR1 16
1.78 +#define SIGUSR2 17
1.79 +#define SIGCLD 18
1.80 +#define SIGPWR 19
1.81 +#define SIGWINCH 20
1.82 +#define SIGPOLL 22 /* 20 for x.out binaries!!!! */
1.83 +#define SIGSTOP 23 /* sendable stop signal not from tty */
1.84 +#define SIGTSTP 24 /* stop signal from tty */
1.85 +#define SIGCONT 25 /* continue a stopped process */
1.86 +#define SIGTTIN 26 /* to readers pgrp upon background tty read */
1.87 +#define SIGTTOU 27 /* like TTIN for output if (tp->t_local<OSTOP) */
1.88 +#define NSIG 28
1.89 +
1.90 +#endif /* _SYS_SIGNAL_H */