From f847d041bc6bf18246bddeff2a219dcbdfa9620c Mon Sep 17 00:00:00 2001 From: Alan Conway Date: Wed, 4 Feb 2009 20:01:52 +0000 Subject: Fix memory error in ClusterPlugin. git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@740849 13f79535-47bb-0310-9956-ffa450edef68 --- cpp/src/qpid/cluster/ClusterPlugin.cpp | 6 ++++-- 1 file changed, 4 insertions(+), 2 deletions(-) (limited to 'cpp/src/qpid/cluster/ClusterPlugin.cpp') diff --git a/cpp/src/qpid/cluster/ClusterPlugin.cpp b/cpp/src/qpid/cluster/ClusterPlugin.cpp index 7e0bdcbea8..2f7d12dcfe 100644 --- a/cpp/src/qpid/cluster/ClusterPlugin.cpp +++ b/cpp/src/qpid/cluster/ClusterPlugin.cpp @@ -158,8 +158,10 @@ struct ClusterPlugin : public Plugin { } } - void initialize(Plugin::Target& ) { - cluster->initialize(); + void initialize(Plugin::Target& target) { + Broker* broker = dynamic_cast(&target); + if (broker && cluster) + cluster->initialize(); } }; -- cgit v1.2.1