fixed: ipc client connected event was being wiped out

daemon now communicates graceful shutdown message through new ipc system.
This commit is contained in:
Nick Bolton 2012-07-05 19:10:04 +00:00
parent 3d6551f708
commit ddb2d7feeb
10 changed files with 44 additions and 38 deletions

View file

@ -121,6 +121,14 @@ CEventQueue::adoptBuffer(IEventQueueBuffer* buffer)
{
CArchMutexLock lock(m_mutex);
LOG((CLOG_DEBUG "adopting new buffer"));
if (m_events.size() != 0) {
// this can come as a nasty surprise to programmers expecting
// their events to be raised, only to have them deleted.
LOG((CLOG_WARN "discarding %d event(s), sorry", m_events.size()));
}
// discard old buffer and old events
delete m_buffer;
for (CEventTable::iterator i = m_events.begin(); i != m_events.end(); ++i) {