version 1.27, 2011/09/12 21:23:00 |
version 1.28, 2012/01/31 08:29:25 |
|
|
warn("fork"); |
warn("fork"); |
continue; |
continue; |
case 0: /* child */ |
case 0: /* child */ |
|
(void)setpgid(getpid(), getpid()); |
(void)setlocale(LC_ALL, ""); |
(void)setlocale(LC_ALL, ""); |
if (setusercontext(NULL, pw, pw->pw_uid, |
if (setusercontext(NULL, pw, pw->pw_uid, |
LOGIN_SETALL ^ LOGIN_SETLOGIN)) |
LOGIN_SETALL ^ LOGIN_SETLOGIN)) |
|
|
/* It doesn't _really_ matter if the kill fails, e.g. |
/* It doesn't _really_ matter if the kill fails, e.g. |
* if there's only a zombie now. |
* if there's only a zombie now. |
*/ |
*/ |
(void)kill(kid, SIGTERM); |
if (getpgid(kid) != getpgrp()) |
|
(void)killpg(getpgid(kid), SIGTERM); |
|
else |
|
(void)kill(kid, SIGTERM); |
warnx("uid %u did not finish in time", pw->pw_uid); |
warnx("uid %u did not finish in time", pw->pw_uid); |
} |
} |
if (time(NULL) - t >= SECSPERDAY) |
if (time(NULL) - t >= SECSPERDAY) |