Author: astitcher
Date: Wed Apr 30 03:41:23 2014
New Revision: 1591183

URL: http://svn.apache.org/r1591183
Log:
QPID-5735: Correct calculation of amqp.redelivered

Modified:
    qpid/trunk/qpid/cpp/src/qpid/broker/Selector.cpp

Modified: qpid/trunk/qpid/cpp/src/qpid/broker/Selector.cpp
URL: 
http://svn.apache.org/viewvc/qpid/trunk/qpid/cpp/src/qpid/broker/Selector.cpp?rev=1591183&r1=1591182&r2=1591183&view=diff
==============================================================================
--- qpid/trunk/qpid/cpp/src/qpid/broker/Selector.cpp (original)
+++ qpid/trunk/qpid/cpp/src/qpid/broker/Selector.cpp Wed Apr 30 03:41:23 2014
@@ -92,7 +92,9 @@ const Value MessageSelectorEnv::specialV
     if ( id=="delivery_mode" ) {
         v = msg.getEncoding().isPersistent() ? PERSISTENT : NON_PERSISTENT;
     } else if ( id=="redelivered" ) {
-        v = msg.getDeliveryCount()>0 ? true : false;
+        // Although redelivered is defined to be true delivery-count>0 if it 
is 0 now
+        // it will be 1 by the time the message is delivered
+        v = msg.getDeliveryCount()>=0 ? true : false;
     } else if ( id=="priority" ) {
         v = int64_t(msg.getPriority());
     } else if ( id=="correlation_id" ) {



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to