summaryrefslogtreecommitdiff
path: root/cpp/src/qpid/cluster/ClusterPlugin.cpp
diff options
context:
space:
mode:
authorAlan Conway <aconway@apache.org>2009-02-04 20:01:52 +0000
committerAlan Conway <aconway@apache.org>2009-02-04 20:01:52 +0000
commitf847d041bc6bf18246bddeff2a219dcbdfa9620c (patch)
tree505eadb9501d74e81ec7ae92b146458b8e0a36b9 /cpp/src/qpid/cluster/ClusterPlugin.cpp
parent35d0d4f0173659f406785f23113c607c09d6041c (diff)
downloadqpid-python-f847d041bc6bf18246bddeff2a219dcbdfa9620c.tar.gz
Fix memory error in ClusterPlugin.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@740849 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src/qpid/cluster/ClusterPlugin.cpp')
-rw-r--r--cpp/src/qpid/cluster/ClusterPlugin.cpp6
1 files changed, 4 insertions, 2 deletions
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<Broker*>(&target);
+ if (broker && cluster)
+ cluster->initialize();
}
};