commit | eddbca6175befbfc2fc3af173a032f8bbd388d87 | [log] [tgz] |
---|---|---|
author | Jeff MAURY <jeffmaury@apache.org> | Sun Mar 22 22:46:03 2015 +0100 |
committer | Jeff MAURY <jeffmaury@apache.org> | Sun Mar 22 22:46:03 2015 +0100 |
tree | 2fd6f44a7cb1bad48cfa6343f27b8b06d7c7cc3a | |
parent | e422ec88defa5da1bd47f01bb952835e2e841b30 [diff] |
Fix for DIRMINA-1008: fix broken algorithm
diff --git a/core/src/main/java/org/apache/mina/util/ByteBufferDumper.java b/core/src/main/java/org/apache/mina/util/ByteBufferDumper.java index 25f79e7..b56e013 100644 --- a/core/src/main/java/org/apache/mina/util/ByteBufferDumper.java +++ b/core/src/main/java/org/apache/mina/util/ByteBufferDumper.java
@@ -143,7 +143,7 @@ ByteBuffer res = ByteBuffer.allocate(size); for (int i = 0; i < size; i++) { - int b = Integer.parseInt(hex.substring(i, i + 2), 16); + int b = Integer.parseInt(hex.substring(i*2, i*2 + 2), 16); if (Integer.highestOneBit(b) == 128) { b = b - 256; }