[an error occurred while processing this directive]
| ||||||||||||
|
| void lock (volatile lock_t *l) { |
l->status[MYSELF] = LOCKED; |
while (l->status[OTHER] == LOCKED) { |
if (l->turn != MYSELF) { |
l->status[MYSELF] = !LOCKED; |
while (l->turn == OTHER) ; |
l->status[MYSELF] = LOCKED; |
| } } } |