File netkit-rsh-0.17-rlogin.diff of Package rsh
--- rlogin/rlogin.c
+++ rlogin/rlogin.c
@@ -421,7 +421,7 @@
void
catch_child(int ignore)
{
- union wait status;
+ int status;
int pid;
(void)ignore;
@@ -432,7 +432,7 @@
return;
/* if the child (reader) dies, just quit */
if (pid < 0 || (pid == childpid && !WIFSTOPPED(status)))
- done((int)(status.w_termsig | status.w_retcode));
+ done((int)(WTERMSIG(status) | WEXITSTATUS(status)));
}
/* NOTREACHED */
}