mirror of
https://github.com/debauchee/barrier.git
synced 2025-08-02 16:19:04 +02:00
fixed Mac server keeps crashing during launch
This commit is contained in:
parent
4816a30db3
commit
95ece5ac2c
1 changed files with 4 additions and 2 deletions
|
@ -31,7 +31,9 @@ class CEventQueueTimer { };
|
|||
//
|
||||
|
||||
COSXEventQueueBuffer::COSXEventQueueBuffer(IEventQueue* events) :
|
||||
m_eventQueue(events), m_event(NULL)
|
||||
m_eventQueue(events),
|
||||
m_event(NULL),
|
||||
m_threadEventQueueRef(NULL)
|
||||
{
|
||||
// do nothing
|
||||
}
|
||||
|
@ -98,7 +100,7 @@ COSXEventQueueBuffer::addEvent(UInt32 dataID)
|
|||
kEventAttributeNone,
|
||||
&event);
|
||||
|
||||
if (error == noErr) {
|
||||
if (error == noErr & m_threadEventQueueRef != NULL) {
|
||||
error = PostEventToQueue(m_threadEventQueueRef, event,
|
||||
kEventPriorityStandard);
|
||||
ReleaseEvent(event);
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue