From c743bf40819e5d6fc5f01ac14137ead21612777a Mon Sep 17 00:00:00 2001 From: Simone Bordet Date: Sat, 25 Aug 2012 10:43:39 +0200 Subject: [PATCH] Jetty9 - Using the correct length when copying bytes, otherwise BufferUnderflowExceptions are thrown. --- .../main/java/org/eclipse/jetty/server/ByteBufferHttpInput.java | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/jetty-server/src/main/java/org/eclipse/jetty/server/ByteBufferHttpInput.java b/jetty-server/src/main/java/org/eclipse/jetty/server/ByteBufferHttpInput.java index 04e367c9098..680deb511f6 100644 --- a/jetty-server/src/main/java/org/eclipse/jetty/server/ByteBufferHttpInput.java +++ b/jetty-server/src/main/java/org/eclipse/jetty/server/ByteBufferHttpInput.java @@ -35,7 +35,7 @@ public class ByteBufferHttpInput extends HttpInput protected int get(ByteBuffer item, byte[] buffer, int offset, int length) { int l = Math.min(item.remaining(), length); - item.get(buffer, offset, length); + item.get(buffer, offset, l); return l; }