diff options
author | Stephen D. Huston <shuston@apache.org> | 2011-10-21 14:42:12 +0000 |
---|---|---|
committer | Stephen D. Huston <shuston@apache.org> | 2011-10-21 14:42:12 +0000 |
commit | f83677056891e436bf5ba99e79240df2a44528cd (patch) | |
tree | 625bfd644b948e89105630759cf6decb0435354d /cpp/examples/messaging | |
parent | ebfd9ff053b04ab379acfc0fefedee5a31b6d8a5 (diff) | |
download | qpid-python-QPID-2519.tar.gz |
Merged out from trunkQPID-2519
git-svn-id: https://svn.apache.org/repos/asf/qpid/branches/QPID-2519@1187375 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'cpp/examples/messaging')
-rw-r--r-- | cpp/examples/messaging/drain.cpp | 4 | ||||
-rw-r--r-- | cpp/examples/messaging/server.cpp | 4 | ||||
-rw-r--r-- | cpp/examples/messaging/spout.cpp | 2 |
3 files changed, 5 insertions, 5 deletions
diff --git a/cpp/examples/messaging/drain.cpp b/cpp/examples/messaging/drain.cpp index 5c938e9742..563e5e5060 100644 --- a/cpp/examples/messaging/drain.cpp +++ b/cpp/examples/messaging/drain.cpp @@ -45,12 +45,12 @@ struct Options : OptionParser url("127.0.0.1"), timeout(0), forever(false), - count(1) + count(0) { add("broker,b", url, "url of broker to connect to"); add("timeout,t", timeout, "timeout in seconds to wait before exiting"); add("forever,f", forever, "ignore timeout and wait forever"); - add("connection-options", connectionOptions, "connection options string in the form {name1=value1, name2=value2}"); + add("connection-options", connectionOptions, "connection options string in the form {name1:value1, name2:value2}"); add("count,c", count, "number of messages to read before exiting"); } diff --git a/cpp/examples/messaging/server.cpp b/cpp/examples/messaging/server.cpp index ab72694c61..aa271d91f9 100644 --- a/cpp/examples/messaging/server.cpp +++ b/cpp/examples/messaging/server.cpp @@ -39,8 +39,8 @@ using std::string; int main(int argc, char** argv) { const char* url = argc>1 ? argv[1] : "amqp:tcp:127.0.0.1:5672"; - std::string connectionOptions = argc > 3 ? argv[3] : ""; - + std::string connectionOptions = argc > 2 ? argv[2] : ""; + Connection connection(url, connectionOptions); try { connection.open(); diff --git a/cpp/examples/messaging/spout.cpp b/cpp/examples/messaging/spout.cpp index 57b955c1de..cd11a7ad81 100644 --- a/cpp/examples/messaging/spout.cpp +++ b/cpp/examples/messaging/spout.cpp @@ -65,7 +65,7 @@ struct Options : OptionParser add("property,P", properties, "specify message property"); add("map,M", entries, "specify entry for map content"); add("content", content, "specify textual content"); - add("connection-options", connectionOptions, "connection options string in the form {name1=value1, name2=value2}"); + add("connection-options", connectionOptions, "connection options string in the form {name1:value1, name2:value2}"); } static bool nameval(const std::string& in, std::string& name, std::string& value) |