Repository: activemq-artemis Updated Branches: refs/heads/master bcecda73f -> cf71b7292
NO-JIRA Remove Property shouldn't invalidate buffer if not found Project: http://git-wip-us.apache.org/repos/asf/activemq-artemis/repo Commit: http://git-wip-us.apache.org/repos/asf/activemq-artemis/commit/cf71b729 Tree: http://git-wip-us.apache.org/repos/asf/activemq-artemis/tree/cf71b729 Diff: http://git-wip-us.apache.org/repos/asf/activemq-artemis/diff/cf71b729 Branch: refs/heads/master Commit: cf71b7292a06438c341fc3677243772e02b79812 Parents: bcecda7 Author: Clebert Suconic <[email protected]> Authored: Thu Feb 16 21:03:24 2017 -0500 Committer: Clebert Suconic <[email protected]> Committed: Thu Feb 16 21:03:38 2017 -0500 ---------------------------------------------------------------------- .../activemq/artemis/core/message/impl/MessageImpl.java | 8 ++++++-- 1 file changed, 6 insertions(+), 2 deletions(-) ---------------------------------------------------------------------- http://git-wip-us.apache.org/repos/asf/activemq-artemis/blob/cf71b729/artemis-core-client/src/main/java/org/apache/activemq/artemis/core/message/impl/MessageImpl.java ---------------------------------------------------------------------- diff --git a/artemis-core-client/src/main/java/org/apache/activemq/artemis/core/message/impl/MessageImpl.java b/artemis-core-client/src/main/java/org/apache/activemq/artemis/core/message/impl/MessageImpl.java index f93086c..5d99da6 100644 --- a/artemis-core-client/src/main/java/org/apache/activemq/artemis/core/message/impl/MessageImpl.java +++ b/artemis-core-client/src/main/java/org/apache/activemq/artemis/core/message/impl/MessageImpl.java @@ -859,9 +859,13 @@ public abstract class MessageImpl implements MessageInternal { @Override public Object removeProperty(final SimpleString key) { - bufferValid = false; + Object oldValue = properties.removeProperty(key); + + if (oldValue != null) { + bufferValid = false; + } - return properties.removeProperty(key); + return oldValue; } @Override
