diff options
author | Philip Wittamore <philip@wittamore.com> | 2025-09-24 22:26:00 +0200 |
---|---|---|
committer | Philip Wittamore <philip@wittamore.com> | 2025-09-24 22:26:00 +0200 |
commit | c2ecaf87e462fd6600ce5ee6a29cb352de042714 (patch) | |
tree | 70f607a8c9bce7f0d40c559ec4112d3dd154eb50 /WWW/Library/Implementation/www_wait.h | |
download | lynx-c2ecaf87e462fd6600ce5ee6a29cb352de042714.tar.gz lynx-c2ecaf87e462fd6600ce5ee6a29cb352de042714.tar.bz2 lynx-c2ecaf87e462fd6600ce5ee6a29cb352de042714.zip |
update
Diffstat (limited to 'WWW/Library/Implementation/www_wait.h')
-rw-r--r-- | WWW/Library/Implementation/www_wait.h | 34 |
1 files changed, 34 insertions, 0 deletions
diff --git a/WWW/Library/Implementation/www_wait.h b/WWW/Library/Implementation/www_wait.h new file mode 100644 index 0000000..3e40e88 --- /dev/null +++ b/WWW/Library/Implementation/www_wait.h @@ -0,0 +1,34 @@ +#ifndef WWW_WAIT_H +#define WWW_WAIT_H 1 + +#include <HTUtils.h> + +#ifdef HAVE_SYS_WAIT_H +#include <sys/wait.h> +#endif + +#ifndef WEXITSTATUS +# ifdef HAVE_TYPE_UNIONWAIT +# define WEXITSTATUS(status) (status.w_retcode) +# else +# define WEXITSTATUS(status) (((status) & 0xff00) >> 8) +# endif +#endif + +#ifndef WTERMSIG +# ifdef HAVE_TYPE_UNIONWAIT +# define WTERMSIG(status) (status.w_termsig) +# else +# define WTERMSIG(status) ((status) & 0x7f) +# endif +#endif + +#ifndef WSTOPSIG +# ifdef HAVE_TYPE_UNIONWAIT +# define WSTOPSIG(status) (status.w_stopsig) +# else +# define WSTOPSIG(status) WEXITSTATUS(status) +# endif +#endif + +#endif /* WWW_WAIT_H */ |