annotate src/syswait.h @ 2371:dd29ab8af9e7

[project @ 1996-10-12 00:09:55 by jwe]
author jwe
date Sat, 12 Oct 1996 00:09:57 +0000
parents 36903d507b0e
children f667d7ec08b9
Ignore whitespace changes - Everywhere: Within whitespace: At end of lines:
rev   line source
1354
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
1 /*
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
2
1884
e62277bf5fe0 [project @ 1996-02-05 18:17:59 by jwe]
jwe
parents: 1354
diff changeset
3 Copyright (C) 1996 John W. Eaton
1354
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
4
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
5 This file is part of Octave.
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
6
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
7 Octave is free software; you can redistribute it and/or modify it
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
8 under the terms of the GNU General Public License as published by the
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
9 Free Software Foundation; either version 2, or (at your option) any
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
10 later version.
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
11
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
12 Octave is distributed in the hope that it will be useful, but WITHOUT
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
13 ANY WARRANTY; without even the implied warranty of MERCHANTABILITY or
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
14 FITNESS FOR A PARTICULAR PURPOSE. See the GNU General Public License
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
15 for more details.
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
16
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
17 You should have received a copy of the GNU General Public License
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
18 along with Octave; see the file COPYING. If not, write to the Free
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
19 Software Foundation, 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
20
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
21 */
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
22
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
23 #if !defined (octave_syswait_h)
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
24 #define octave_syswait_h 1
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
25
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
26 // This mess suggested by the autoconf manual.
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
27
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
28 #include <sys/types.h>
2095
36903d507b0e [project @ 1996-04-28 09:00:07 by jwe]
jwe
parents: 1996
diff changeset
29
1354
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
30 #if HAVE_SYS_WAIT_H
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
31 #include <sys/wait.h>
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
32 #endif
2095
36903d507b0e [project @ 1996-04-28 09:00:07 by jwe]
jwe
parents: 1996
diff changeset
33
36903d507b0e [project @ 1996-04-28 09:00:07 by jwe]
jwe
parents: 1996
diff changeset
34 #ifndef WIFEXITED
36903d507b0e [project @ 1996-04-28 09:00:07 by jwe]
jwe
parents: 1996
diff changeset
35 #define WIFEXITED(stat_val) (((stat_val) & 255) == 0)
36903d507b0e [project @ 1996-04-28 09:00:07 by jwe]
jwe
parents: 1996
diff changeset
36 #endif
36903d507b0e [project @ 1996-04-28 09:00:07 by jwe]
jwe
parents: 1996
diff changeset
37
1354
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
38 #ifndef WEXITSTATUS
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
39 #define WEXITSTATUS(stat_val) ((unsigned)(stat_val) >> 8)
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
40 #endif
2095
36903d507b0e [project @ 1996-04-28 09:00:07 by jwe]
jwe
parents: 1996
diff changeset
41
36903d507b0e [project @ 1996-04-28 09:00:07 by jwe]
jwe
parents: 1996
diff changeset
42 #ifndef WIFSIGNALLED
36903d507b0e [project @ 1996-04-28 09:00:07 by jwe]
jwe
parents: 1996
diff changeset
43 #define WIFSIGNALLED(stat_val) \
36903d507b0e [project @ 1996-04-28 09:00:07 by jwe]
jwe
parents: 1996
diff changeset
44 (((stat_val) & 0177) != 0177 && ((stat_val) & 0177) != 0)
1354
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
45 #endif
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
46
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
47 #endif
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
48
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
49 /*
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
50 ;;; Local Variables: ***
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
51 ;;; mode: C++ ***
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
52 ;;; End: ***
5b54091471dd [project @ 1995-09-05 19:56:08 by jwe]
jwe
parents:
diff changeset
53 */