mirror of https://github.com/deavmi/eventy.git
Fixed bug where mutex lock object was 0 addr
This commit is contained in:
parent
fd4bcb7ecd
commit
3a2637605a
|
@ -20,6 +20,12 @@ public final class Queue
|
||||||
private Mutex queueLock;
|
private Mutex queueLock;
|
||||||
|
|
||||||
|
|
||||||
|
this(ulong id)
|
||||||
|
{
|
||||||
|
this.id = id;
|
||||||
|
queueLock = new Mutex();
|
||||||
|
}
|
||||||
|
|
||||||
public void add(Event e)
|
public void add(Event e)
|
||||||
{
|
{
|
||||||
/* Lock the queue */
|
/* Lock the queue */
|
||||||
|
@ -38,7 +44,7 @@ public final class Queue
|
||||||
/* Lock the queue */
|
/* Lock the queue */
|
||||||
queueLock.lock();
|
queueLock.lock();
|
||||||
|
|
||||||
has = (queue[]).empty();
|
has = !(queue[]).empty();
|
||||||
|
|
||||||
/* Unlock the queue */
|
/* Unlock the queue */
|
||||||
queueLock.unlock();
|
queueLock.unlock();
|
||||||
|
|
Loading…
Reference in New Issue