Back to index

glibc  2.9
siginfo.h
Go to the documentation of this file.
00001 /* Definitions of the siginfo structure.
00002    Copyright (C) 1993, 1994, 1997 Free Software Foundation, Inc.
00003    This file is part of the GNU C Library.
00004    Contributed by Brendan Kehoe (brendan@zen.org).
00005 
00006    The GNU C Library is free software; you can redistribute it and/or
00007    modify it under the terms of the GNU Lesser General Public
00008    License as published by the Free Software Foundation; either
00009    version 2.1 of the License, or (at your option) any later version.
00010 
00011    The GNU C Library is distributed in the hope that it will be useful,
00012    but WITHOUT ANY WARRANTY; without even the implied warranty of
00013    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE.  See the GNU
00014    Lesser General Public License for more details.
00015 
00016    You should have received a copy of the GNU Lesser General Public
00017    License along with the GNU C Library; if not, write to the Free
00018    Software Foundation, Inc., 59 Temple Place, Suite 330, Boston, MA
00019    02111-1307 USA.  */
00020 
00021 #ifndef       _SIGINFO_H
00022 #define       _SIGINFO_H    1
00023 
00024 #ifdef __USE_SVID
00025 /* SVR4 puts a ton of other stuff in this structure.  For now, we'll just
00026    define the two things we really need out of it, and hope for the best.  */
00027 
00028 /* These define the different states a child can have on exit.
00029    We need these to build the status return for things like waitpid.  */
00030 #define EXITED              1
00031 #define KILLED              2
00032 #define CORED        3
00033 #define TRAPPED             4
00034 #define STOPPED             5
00035 #define CONTINUED    6
00036 
00037 typedef struct __siginfo
00038   {
00039     int filler1;
00040 
00041     /* Code indicating child's status */
00042     int __code;
00043 
00044     int filler2;
00045 
00046     /* The PID of the child.  */
00047     long __pid;
00048 
00049     int filler3;
00050 
00051     /* The child's status.  */
00052     int __status;
00053 
00054     int filler4[26];
00055 
00056   } __siginfo_t;
00057 
00058 #endif  /* __USE_SVID */
00059 #endif /* siginfo.h */