summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorKenneth Anthony Giusti <kgiusti@apache.org>2012-06-05 16:52:14 +0000
committerKenneth Anthony Giusti <kgiusti@apache.org>2012-06-05 16:52:14 +0000
commit99cb52f7d480e7df249fd7b949360e8204cc01e3 (patch)
tree090652bb932150732ba46d462ff35197a8b2b9f5
parentdf7467bc8cd60e584295f4e643654e4dd26b39b0 (diff)
downloadqpid-python-99cb52f7d480e7df249fd7b949360e8204cc01e3.tar.gz
QPID-4041: move check for transport after setting value.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@1346462 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r--cpp/src/qpid/broker/Broker.cpp10
1 files changed, 5 insertions, 5 deletions
diff --git a/cpp/src/qpid/broker/Broker.cpp b/cpp/src/qpid/broker/Broker.cpp
index b550156c00..89c9c3fb37 100644
--- a/cpp/src/qpid/broker/Broker.cpp
+++ b/cpp/src/qpid/broker/Broker.cpp
@@ -747,11 +747,6 @@ void Broker::createObject(const std::string& type, const std::string& name,
bool durable = false;
std::string authMech, username, password;
- if (!getProtocolFactory(transport)) {
- QPID_LOG(error, "Transport '" << transport << "' not supported.");
- throw UnsupportedTransport(transport);
- }
-
for (Variant::Map::const_iterator i = properties.begin(); i != properties.end(); ++i) {
if (i->first == HOST) host = i->second.asString();
else if (i->first == PORT) port = i->second.asUint16();
@@ -765,6 +760,11 @@ void Broker::createObject(const std::string& type, const std::string& name,
}
}
+ if (!getProtocolFactory(transport)) {
+ QPID_LOG(error, "Transport '" << transport << "' not supported.");
+ throw UnsupportedTransport(transport);
+ }
+
std::pair<boost::shared_ptr<Link>, bool> rc;
rc = links.declare(name, host, port, transport, durable, authMech, username, password);
if (!rc.first) {