6954621: small error in 6948909

Reviewed-by: xuelei
This commit is contained in:
Weijun Wang 2010-05-24 09:28:25 +08:00
parent 874ec0972c
commit 6e9dba43a0

View File

@ -1486,7 +1486,7 @@ public class JarSigner {
for (int i=0; i<len; i++) {
switch (bs[i]) {
case '\r':
if (i < len && bs[i+1] == '\n') i++;
if (i < len - 1 && bs[i+1] == '\n') i++;
// fallthrough
case '\n':
if (newline) return i+1; //+1 to get length