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 | b61bc77ec5a871cf5319ac770a78466d51334f20 (patch) | |
tree | 064121a35bb612f13de30ef075d22f1a221c3f37 /cpp/src | |
parent | 8d6bc01b5c2232b3d06ed45e051f0c066cd6ec71 (diff) | |
download | qpid-python-b61bc77ec5a871cf5319ac770a78466d51334f20.tar.gz |
QPID-2426: Check for empty name in address when resolving
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@918573 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/src')
-rw-r--r-- | cpp/src/qpid/client/amqp0_10/AddressResolution.cpp | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/cpp/src/qpid/client/amqp0_10/AddressResolution.cpp b/cpp/src/qpid/client/amqp0_10/AddressResolution.cpp index f1b487c255..f81086db99 100644 --- a/cpp/src/qpid/client/amqp0_10/AddressResolution.cpp +++ b/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()); |