Small modification to my prev change:

1) set aborting flags for all signals because tsleep exited
not by timeout and not by wakeup.
2) Simplify expression.
This commit is contained in:
Andrey A. Chernov 1996-01-16 12:29:37 +00:00
parent 158a4a24fa
commit 5ce1b6a98e
Notes: svn2git 2020-12-20 02:59:44 +00:00
svn path=/head/; revision=13462

View File

@ -189,13 +189,11 @@ struct snd_wait {
f.mode = WK_SLEEP; \
flag=tsleep(&q, (PRIBIO-5)|PCATCH, "sndint", time_limit); \
f.mode &= ~WK_SLEEP; \
if (flag == EINTR) \
f.aborting = 1; \
else { \
if (flag == EWOULDBLOCK) { \
f.mode |= WK_TIMEOUT; \
f.aborting = 0; \
if (flag == EWOULDBLOCK) \
f.mode |= WK_TIMEOUT; \
} \
} else \
f.aborting = flag; \
}
/* An the following wakes up a process */
#define WAKE_UP(q, f) wakeup(&q)