summaryrefslogtreecommitdiff
path: root/cpp/src/IceStorm/Flusher.cpp
diff options
context:
space:
mode:
authorMark Spruiell <mes@zeroc.com>2003-05-28 04:28:41 +0000
committerMark Spruiell <mes@zeroc.com>2003-05-28 04:28:41 +0000
commitac88e6ceea41685c5a2e1611b6d56d309f039f3e (patch)
tree5cb594a9c1f0d6d319862018826d724d5c4fa4ab /cpp/src/IceStorm/Flusher.cpp
parentFixed typo (diff)
downloadice-ac88e6ceea41685c5a2e1611b6d56d309f039f3e.tar.bz2
ice-ac88e6ceea41685c5a2e1611b6d56d309f039f3e.tar.xz
ice-ac88e6ceea41685c5a2e1611b6d56d309f039f3e.zip
fixing memory leak
Diffstat (limited to 'cpp/src/IceStorm/Flusher.cpp')
-rw-r--r--cpp/src/IceStorm/Flusher.cpp9
1 files changed, 6 insertions, 3 deletions
diff --git a/cpp/src/IceStorm/Flusher.cpp b/cpp/src/IceStorm/Flusher.cpp
index 8dae4d5cce8..4ef6b3374d1 100644
--- a/cpp/src/IceStorm/Flusher.cpp
+++ b/cpp/src/IceStorm/Flusher.cpp
@@ -70,6 +70,11 @@ public:
}
flushAll();
}
+
+ //
+ // We break a cycle by clearing the subscriber list.
+ //
+ _subscribers.clear();
}
void
@@ -162,8 +167,6 @@ Flusher::Flusher(const Ice::CommunicatorPtr& communicator, const TraceLevelsPtr&
Flusher::~Flusher()
{
- _thread->destroy();
- _thread->getThreadControl().join();
}
void
@@ -182,5 +185,5 @@ void
Flusher::stopFlushing()
{
_thread->destroy();
+ _thread->getThreadControl().join();
}
-