Skip to content

Commit

Permalink
ctf.core: Explicitly align to support 0-length sequences
Browse files Browse the repository at this point in the history
Resolves #58

Signed-off-by: Christophe Bedard <christophe.bedard@apex.ai>
  • Loading branch information
christophebedard authored and MatthewKhouzam committed Apr 12, 2024
1 parent 57e7774 commit 80cff44
Showing 1 changed file with 3 additions and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -121,6 +121,9 @@ public AbstractArrayDefinition createDefinition(
throw new CTFException("Sequence length too long " + length); //$NON-NLS-1$
}

// Explicitly align to support 0-length sequences
alignRead(input);

if (isAlignedBytes()) {
// Don't create "useless" definitions
byte[] data = new byte[(int) length];
Expand Down

0 comments on commit 80cff44

Please sign in to comment.