Add a function to AsyncQueue to tell if we are connected
This commit is contained in:
11
asyncqueue.c
11
asyncqueue.c
@@ -1238,3 +1238,14 @@ void *AsyncUnitGetQueueContext(pAsyncUnit unit)
|
||||
assert(unit->queue);
|
||||
return unit->queue->context;
|
||||
}
|
||||
|
||||
|
||||
int AsyncUnitIsQueueConnected(pAsyncUnit unit)
|
||||
{
|
||||
assert(unit);
|
||||
assert(unit->queue);
|
||||
if (unit && unit->queue)
|
||||
if (unit->queue->state == eAsyncConnected)
|
||||
return 1;
|
||||
return 0;
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user