Check if all the queues are empty
| 131 | |
| 132 | // Check if all the queues are empty |
| 133 | bool MessageBuffer::transmitBufferEmpty() const |
| 134 | { |
| 135 | bool isEmpty = true; |
| 136 | for (MessageQueues::const_iterator it = m_msgQueues.begin(); |
| 137 | it != m_msgQueues.end(); ++it) { |
| 138 | if (!it->empty()) { |
| 139 | cerr |
| 140 | << opt::rank << ": error: tx buffer should be empty: " |
| 141 | << it->size() << " messages from " |
| 142 | << opt::rank << " to " << it - m_msgQueues.begin() |
| 143 | << '\n'; |
| 144 | for (MsgBuffer::const_iterator j = it->begin(); |
| 145 | j != it->end(); ++j) |
| 146 | cerr << **j << '\n'; |
| 147 | isEmpty = false; |
| 148 | } |
| 149 | } |
| 150 | return isEmpty; |
| 151 | } |