diff --git a/vertx-core/src/main/java/io/vertx/core/json/jackson/HybridJacksonPool.java b/vertx-core/src/main/java/io/vertx/core/json/jackson/HybridJacksonPool.java index f61fd441d83..99b6d9d1b73 100644 --- a/vertx-core/src/main/java/io/vertx/core/json/jackson/HybridJacksonPool.java +++ b/vertx-core/src/main/java/io/vertx/core/json/jackson/HybridJacksonPool.java @@ -142,8 +142,8 @@ public void releasePooled(BufferRecycler recycler) { Node next = topStacks.get(vThreadBufferRecycler.slot); while (true) { newHead.level = next == null ? 1 : next.level + 1; + newHead.next = next; if (topStacks.compareAndSet(vThreadBufferRecycler.slot, next, newHead)) { - newHead.next = next; return; } else { next = topStacks.get(vThreadBufferRecycler.slot);