seijikun: Fix new unit-test introduced with #125
This commit is contained in:
parent
88c82d3740
commit
093bd35c44
@ -62,10 +62,6 @@ public class CalculateAverage_seijikun {
|
|||||||
|
|
||||||
public StationIdent(byte[] name, int nameHash) {
|
public StationIdent(byte[] name, int nameHash) {
|
||||||
this.name = name;
|
this.name = name;
|
||||||
// TODO: DEBUG
|
|
||||||
// if(Arrays.asList(this.name).contains(';')) {
|
|
||||||
// throw new RuntimeException();
|
|
||||||
// }
|
|
||||||
this.nameHash = nameHash;
|
this.nameHash = nameHash;
|
||||||
}
|
}
|
||||||
|
|
||||||
@ -122,7 +118,7 @@ public class CalculateAverage_seijikun {
|
|||||||
private StationIdent readStationName() {
|
private StationIdent readStationName() {
|
||||||
final var VECTOR_SPECIES = ByteVector.SPECIES_256;
|
final var VECTOR_SPECIES = ByteVector.SPECIES_256;
|
||||||
|
|
||||||
if (chunkSize - ptr < VECTOR_SPECIES.length()) { // fallback
|
if (chunkSize - ptr - 100 < VECTOR_SPECIES.length()) { // fallback
|
||||||
int startPtr = ptr;
|
int startPtr = ptr;
|
||||||
while (buffer.get(ptr++) != ';') {
|
while (buffer.get(ptr++) != ';') {
|
||||||
}
|
}
|
||||||
|
Loading…
Reference in New Issue
Block a user