summaryrefslogtreecommitdiff
path: root/qpid/cpp/examples/messaging/hello_world.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'qpid/cpp/examples/messaging/hello_world.cpp')
-rw-r--r--qpid/cpp/examples/messaging/hello_world.cpp4
1 files changed, 3 insertions, 1 deletions
diff --git a/qpid/cpp/examples/messaging/hello_world.cpp b/qpid/cpp/examples/messaging/hello_world.cpp
index 9c06964a66..8aef57d5d0 100644
--- a/qpid/cpp/examples/messaging/hello_world.cpp
+++ b/qpid/cpp/examples/messaging/hello_world.cpp
@@ -11,7 +11,9 @@ using namespace qpid::messaging;
int main(int argc, char** argv) {
std::string broker = argc > 1 ? argv[1] : "localhost:5672";
std::string address = argc > 2 ? argv[2] : "amq.topic";
- Connection connection(broker);
+ std::string connectionOptions = argc > 3 ? argv[3] : "";
+
+ Connection connection(broker, connectionOptions);
try {
connection.open();
Session session = connection.createSession();