GDB (xrefs)
Macros
gdb_wait.h File Reference
#include <sys/wait.h>

Go to the source code of this file.

Macros

#define WIFEXITED(w)   (((w)&0377) == 0)
 
#define WIFSIGNALED(w)   (((w)&0377) != 0177 && ((w)&~0377) == 0)
 
#define WIFSTOPPED(w)   (((w)&0377) == 0177)
 
#define WEXITSTATUS(w)   (((w) >> 8) & 0377) /* same as WRETCODE */
 
#define WTERMSIG(w)   ((w) & 0177)
 
#define WSTOPSIG   WEXITSTATUS
 
#define WSETEXIT(w, status)   ((w) = (0 | ((status) << 8)))
 
#define W_STOPCODE(sig)   ((sig) << 8 | 0x7f)
 
#define WSETSTOP(w, sig)   ((w) = W_STOPCODE(sig))
 
#define WNOHANG   1 /* Don't block waiting. */
 
#define WUNTRACED   2 /* Report status of stopped children. */
 
#define __WCLONE   0x80000000 /* Wait for cloned process. */
 

Macro Definition Documentation

◆ __WCLONE

#define __WCLONE   0x80000000 /* Wait for cloned process. */

Definition at line 110 of file gdb_wait.h.

Referenced by spu_child_wait().

◆ W_STOPCODE

#define W_STOPCODE (   sig)    ((sig) << 8 | 0x7f)

Definition at line 89 of file gdb_wait.h.

Referenced by linux_child_follow_fork(), linux_nat_filter_event(), and wait_lwp().

◆ WEXITSTATUS

#define WEXITSTATUS (   w)    (((w) >> 8) & 0377) /* same as WRETCODE */

◆ WIFEXITED

#define WIFEXITED (   w)    (((w)&0377) == 0)

◆ WIFSIGNALED

#define WIFSIGNALED (   w)    (((w)&0377) != 0177 && ((w)&~0377) == 0)

◆ WIFSTOPPED

#define WIFSTOPPED (   w)    (((w)&0377) == 0177)

◆ WNOHANG

#define WNOHANG   1 /* Don't block waiting. */

◆ WSETEXIT

#define WSETEXIT (   w,
  status 
)    ((w) = (0 | ((status) << 8)))

Definition at line 84 of file gdb_wait.h.

◆ WSETSTOP

#define WSETSTOP (   w,
  sig 
)    ((w) = W_STOPCODE(sig))

Definition at line 93 of file gdb_wait.h.

◆ WSTOPSIG

#define WSTOPSIG   WEXITSTATUS

◆ WTERMSIG

#define WTERMSIG (   w)    ((w) & 0177)

◆ WUNTRACED

#define WUNTRACED   2 /* Report status of stopped children. */

Definition at line 106 of file gdb_wait.h.

Referenced by gnu_wait().