aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNIIBE Yutaka <gniibe@fsij.org>2016-05-18 17:00:25 +0900
committerNIIBE Yutaka <gniibe@fsij.org>2016-05-18 17:00:25 +0900
commit5e33e7f468eda8466da1dd55cacc88ee4915d18f (patch)
treed0eeb1154bda600cd86b3cc14f8740e088995eb0
parentdb413813b6cd8a0891805a1111824ffd4d5a3737 (diff)
fix eventflag
-rw-r--r--eventflag.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/eventflag.c b/eventflag.c
index c30d40c..5fc5db5 100644
--- a/eventflag.c
+++ b/eventflag.c
@@ -48,7 +48,7 @@ eventflag_wait (struct eventflag *ev)
chopstx_mutex_lock (&ev->mutex);
if (!ev->flags)
- chopstx_cond_wait (&ev->u.cond, &ev->mutex);
+ chopstx_cond_wait (&ev->cond, &ev->mutex);
n = __builtin_ffs (ev->flags);
ev->flags &= ~(1 << (n - 1));
@@ -100,7 +100,7 @@ void
eventflag_signal (struct eventflag *ev, eventmask_t m)
{
chopstx_mutex_lock (&ev->mutex);
- ev->flag |= m;
- chopstx_cond_signal (&ev->u.cond);
+ ev->flags |= m;
+ chopstx_cond_signal (&ev->cond);
chopstx_mutex_unlock (&ev->mutex);
}