You are viewing a plain text version of this content. The canonical link for it is here.
Posted to commits@qpid.apache.org by gs...@apache.org on 2009/06/25 19:06:51 UTC
svn commit: r788439 - /qpid/trunk/qpid/cpp/src/qpid/Options.cpp
Author: gsim
Date: Thu Jun 25 17:06:51 2009
New Revision: 788439
URL: http://svn.apache.org/viewvc?rev=788439&view=rev
Log:
Require exact match for environment variables before they are interpreted as options (rather than simply matching as a prefix to an option name).
Modified:
qpid/trunk/qpid/cpp/src/qpid/Options.cpp
Modified: qpid/trunk/qpid/cpp/src/qpid/Options.cpp
URL: http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/qpid/Options.cpp?rev=788439&r1=788438&r2=788439&view=diff
==============================================================================
--- qpid/trunk/qpid/cpp/src/qpid/Options.cpp (original)
+++ qpid/trunk/qpid/cpp/src/qpid/Options.cpp Thu Jun 25 17:06:51 2009
@@ -55,7 +55,8 @@
}
static bool matchStr(const string& env, boost::shared_ptr<po::option_description> desc) {
- return std::equal(env.begin(), env.end(), desc->long_name().begin(), &matchChar);
+ return desc->long_name().size() == env.size() &&
+ std::equal(env.begin(), env.end(), desc->long_name().begin(), &matchChar);
}
static bool matchCase(const string& env, boost::shared_ptr<po::option_description> desc) {
---------------------------------------------------------------------
Apache Qpid - AMQP Messaging Implementation
Project: http://qpid.apache.org
Use/Interact: mailto:commits-subscribe@qpid.apache.org