|
|
@ -161,7 +161,12 @@ public: |
|
|
|
{ |
|
|
|
{ |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
friend class CCheckQueueControl<T>; |
|
|
|
bool IsIdle() |
|
|
|
|
|
|
|
{ |
|
|
|
|
|
|
|
boost::unique_lock<boost::mutex> lock(mutex); |
|
|
|
|
|
|
|
return (nTotal == nIdle && nTodo == 0 && fAllOk == true); |
|
|
|
|
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|
}; |
|
|
|
}; |
|
|
|
|
|
|
|
|
|
|
|
/**
|
|
|
|
/**
|
|
|
@ -180,9 +185,8 @@ public: |
|
|
|
{ |
|
|
|
{ |
|
|
|
// passed queue is supposed to be unused, or NULL
|
|
|
|
// passed queue is supposed to be unused, or NULL
|
|
|
|
if (pqueue != NULL) { |
|
|
|
if (pqueue != NULL) { |
|
|
|
assert(pqueue->nTotal == pqueue->nIdle); |
|
|
|
bool isIdle = pqueue->IsIdle(); |
|
|
|
assert(pqueue->nTodo == 0); |
|
|
|
assert(isIdle); |
|
|
|
assert(pqueue->fAllOk == true); |
|
|
|
|
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
} |
|
|
|
|
|
|
|
|
|
|
|