/// <param name="_PMessage">\r
/// A pointer to a new message.\r
/// </param>\r
- virtual void propagate_to_any_targets(message<_Type> * _PMessage)\r
+ virtual void propagate_to_any_targets(message<_Type> * _PMessage)\r
{\r
// Enqueue pMessage to the internal message buffer if it is non-NULL.\r
// pMessage can be NULL if this LWT was the result of a Repropagate call\r
- // out of a Consume or Release (where no new message is queued up, but\r
+ // out of a Consume or Release (where no new message is queued up, but\r
// everything remaining in the bounded buffer needs to be propagated out)\r
if (_PMessage != NULL)\r
{\r
// If the incoming pMessage is not the head message, we can safely assume that\r
// the head message is blocked and waiting on Consume(), Release() or a new\r
// link_target() and cannot be propagated out.\r
- if (_M_messageBuffer.is_head(_PMessage->msg_id()))\r
+ if (!_M_messageBuffer.is_head(_PMessage->msg_id()))\r
{\r
- _Propagate_priority_order();\r
+ return;\r
}\r
}\r
- else\r
+\r
+ _Propagate_priority_order();\r
+ \r
{\r
+\r
// While current size is less than capacity try to consume\r
// any previously offered ids.\r
bool _ConsumedMsg = true;\r