(shutdwn): No longer a signal handler, no need to avoid sleeping.

This lets player threads send C_EXIT properly even when the server
shuts down on a signal.
This commit is contained in:
Markus Armbruster 2006-06-07 21:45:46 +00:00
parent 8562a40136
commit 5c7e97c522

View file

@ -374,14 +374,8 @@ shutdwn(int sig)
empth_wakeup(p->proc);
}
if (!sig) {
/* Sleep and let some cleanup happen - note this doesn't work
when called from a signal handler, since we may or may not
be in the right thread. So we just pass by and kill 'em
all. */
time(&now);
empth_sleep(now + 1);
}
time(&now);
empth_sleep(now + 1);
for (p = player_next(0); p != 0; p = player_next(p)) {
p->state = PS_KILL;