Lines Matching defs:notifyData
91 typedef struct notifyData {
101 NotifyData *notifyData = (NotifyData*)arg;
102 PR_Lock(notifyData->ml);
103 while (notifyData->counter > 0)
105 while (!notifyData->pending)
106 PR_WaitCondVar(notifyData->child, PR_INTERVAL_NO_TIMEOUT);
107 notifyData->counter -= 1;
108 notifyData->pending = PR_FALSE;
109 PR_NotifyCondVar(notifyData->parent);
111 PR_Unlock(notifyData->ml);
133 NotifyData notifyData;
138 notifyData.counter = loops;
139 notifyData.ml = PR_NewLock();
140 notifyData.child = PR_NewCondVar(notifyData.ml);
141 notifyData.parent = PR_NewCondVar(notifyData.ml);
143 PR_USER_THREAD, Notifier, ¬ifyData,
149 PR_Lock(notifyData.ml);
150 while (notifyData.counter > 0)
152 notifyData.pending = PR_TRUE;
153 PR_NotifyCondVar(notifyData.child);
154 while (notifyData.pending)
155 PR_WaitCondVar(notifyData.parent, PR_INTERVAL_NO_TIMEOUT);
157 PR_Unlock(notifyData.ml);
162 PR_DestroyCondVar(notifyData.child);
163 PR_DestroyCondVar(notifyData.parent);
164 PR_DestroyLock(notifyData.ml);