diff options
author | Gordon Sim <gsim@apache.org> | 2010-03-03 17:06:05 +0000 |
---|---|---|
committer | Gordon Sim <gsim@apache.org> | 2010-03-03 17:06:05 +0000 |
commit | 9ebaf89fcaff1bf2f061e514cba4de0ee4110349 (patch) | |
tree | a2b440c682ddc983b6f08d709955e27294be796f | |
parent | 46cbccacaf45190937edac7c82df041d8c8086cc (diff) | |
download | qpid-python-9ebaf89fcaff1bf2f061e514cba4de0ee4110349.tar.gz |
QPID-2426: Check for empty name in address when resolving
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk@918573 13f79535-47bb-0310-9956-ffa450edef68
-rw-r--r-- | qpid/cpp/src/qpid/client/amqp0_10/AddressResolution.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/qpid/cpp/src/qpid/client/amqp0_10/AddressResolution.cpp b/qpid/cpp/src/qpid/client/amqp0_10/AddressResolution.cpp index f1b487c255..f81086db99 100644 --- a/qpid/cpp/src/qpid/client/amqp0_10/AddressResolution.cpp +++ b/qpid/cpp/src/qpid/client/amqp0_10/AddressResolution.cpp @@ -277,6 +277,9 @@ bool AddressResolution::is_reliable(const Address& address) std::string checkAddressType(qpid::client::Session session, const Address& address) { + if (address.getName().empty()) { + throw InvalidAddress("Name cannot be null"); + } std::string type = address.getType(); if (type.empty()) { ExchangeBoundResult result = session.exchangeBound(arg::exchange=address.getName(), arg::queue=address.getName()); |