Author: j16sdiz
Date: 2008-10-23 13:35:54 +0000 (Thu, 23 Oct 2008)
New Revision: 23045

Modified:
   trunk/freenet/src/freenet/support/io/PaddedEphemerallyEncryptedBucket.java
Log:
off-by-one in PaddedEphemerallyEncryptedInputStream.read()

Modified: 
trunk/freenet/src/freenet/support/io/PaddedEphemerallyEncryptedBucket.java
===================================================================
--- trunk/freenet/src/freenet/support/io/PaddedEphemerallyEncryptedBucket.java  
2008-10-23 09:43:15 UTC (rev 23044)
+++ trunk/freenet/src/freenet/support/io/PaddedEphemerallyEncryptedBucket.java  
2008-10-23 13:35:54 UTC (rev 23045)
@@ -225,7 +225,7 @@

                @Override
                public int read() throws IOException {
-                       if(ptr > dataLength) return -1;
+                       if(ptr >= dataLength) return -1;
                        int x = in.read();
                        if(x == -1) return x;
                        ptr++;


Reply via email to