diff options
| author | Rajith Muditha Attapattu <rajith@apache.org> | 2010-01-08 21:19:25 +0000 |
|---|---|---|
| committer | Rajith Muditha Attapattu <rajith@apache.org> | 2010-01-08 21:19:25 +0000 |
| commit | 4810aa28757f68689b8c1c3fe931afb1f9df02bd (patch) | |
| tree | bf8c461a27120365fa26ea8b93299a6fc7f8f830 /java/common/src/main | |
| parent | ffbda30fd1ef1652ffc4cfbdf46d0b670a28f860 (diff) | |
| download | qpid-python-4810aa28757f68689b8c1c3fe931afb1f9df02bd.tar.gz | |
There is mistake in a commit made for QPID-1830 in rev 891805
Due to the mistake a get operation could reference an index out of bounds or it could print fewer items than what is required.
This commit corrects that mistake.
git-svn-id: https://svn.apache.org/repos/asf/qpid/trunk/qpid@897323 13f79535-47bb-0310-9956-ffa450edef68
Diffstat (limited to 'java/common/src/main')
| -rw-r--r-- | java/common/src/main/java/org/apache/qpid/transport/util/Functions.java | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/java/common/src/main/java/org/apache/qpid/transport/util/Functions.java b/java/common/src/main/java/org/apache/qpid/transport/util/Functions.java index 9f1c0ca9eb..5761228642 100644 --- a/java/common/src/main/java/org/apache/qpid/transport/util/Functions.java +++ b/java/common/src/main/java/org/apache/qpid/transport/util/Functions.java @@ -65,9 +65,9 @@ public class Functions StringBuilder str = new StringBuilder(); str.append('"'); - for (int i = 0; i < min(buf.remaining(), limit); i++) + for (int i = start; i < min(buf.limit(), limit); i++) { - byte c = buf.get(start + i); + byte c = buf.get(i); if (c > 31 && c < 127 && c != '\\') { |
