pdfbox-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From le...@apache.org
Subject svn commit: r1685453 - /pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/io/RandomAccessBuffer.java
Date Sun, 14 Jun 2015 20:12:19 GMT
Author: lehmi
Date: Sun Jun 14 20:12:19 2015
New Revision: 1685453

URL: http://svn.apache.org/r1685453
Log:
PDFBOX-2301, PDFBOX-2829: take the given offset into account

Modified:
    pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/io/RandomAccessBuffer.java

Modified: pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/io/RandomAccessBuffer.java
URL: http://svn.apache.org/viewvc/pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/io/RandomAccessBuffer.java?rev=1685453&r1=1685452&r2=1685453&view=diff
==============================================================================
--- pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/io/RandomAccessBuffer.java (original)
+++ pdfbox/trunk/pdfbox/src/main/java/org/apache/pdfbox/io/RandomAccessBuffer.java Sun Jun
14 20:12:19 2015
@@ -241,7 +241,7 @@ public class RandomAccessBuffer implemen
         int bytesRead = readRemainingBytes(b, offset, length);
         while (bytesRead < length && available() > 0)
         {
-            bytesRead += readRemainingBytes(b, bytesRead, length - bytesRead);
+            bytesRead += readRemainingBytes(b, offset + bytesRead, length - bytesRead);
             if (currentBufferPointer == chunkSize)
             {
                 nextBuffer();



Mime
View raw message