Increase allowable range for BCF2 by -1 on low-end
This commit is contained in:
parent
4cbd11faf5
commit
4d3fad38e9
|
|
@ -48,8 +48,7 @@ public enum BCF2Type {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
// todo -- confirm range
|
INT8 (1, 1, 0xFFFFFF80, -128, 127) {
|
||||||
INT8 (1, 1, 0xFFFFFF80, -127, 127) {
|
|
||||||
@Override
|
@Override
|
||||||
public int read(final InputStream in) throws IOException {
|
public int read(final InputStream in) throws IOException {
|
||||||
return BCF2Utils.readByte(in);
|
return BCF2Utils.readByte(in);
|
||||||
|
|
@ -61,7 +60,7 @@ public enum BCF2Type {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
INT16(2, 2, 0xFFFF8000, -32767, 32767) {
|
INT16(2, 2, 0xFFFF8000, -32768, 32767) {
|
||||||
@Override
|
@Override
|
||||||
public int read(final InputStream in) throws IOException {
|
public int read(final InputStream in) throws IOException {
|
||||||
final int b2 = BCF2Utils.readByte(in) & 0xFF;
|
final int b2 = BCF2Utils.readByte(in) & 0xFF;
|
||||||
|
|
@ -77,7 +76,7 @@ public enum BCF2Type {
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
INT32(3, 4, 0x80000000, -2147483647, 2147483647) {
|
INT32(3, 4, 0x80000000, -2147483648, 2147483647) {
|
||||||
@Override
|
@Override
|
||||||
public int read(final InputStream in) throws IOException {
|
public int read(final InputStream in) throws IOException {
|
||||||
final int b4 = BCF2Utils.readByte(in) & 0xFF;
|
final int b4 = BCF2Utils.readByte(in) & 0xFF;
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue