Properly feed an EOS token to the push down automata in OpenPgpMessageInputStream.read()

This commit is contained in:
Paul Schaub 2023-11-27 13:27:23 +01:00
parent 1e33408098
commit b0caa95378
Signed by: vanitasvitae
GPG Key ID: 62BEE9264BF17311
1 changed files with 1 additions and 0 deletions

View File

@ -486,6 +486,7 @@ class OpenPgpMessageInputStream(
override fun read(): Int {
if (nestedInputStream == null) {
if (packetInputStream != null) {
syntaxVerifier.next(InputSymbol.END_OF_SEQUENCE)
syntaxVerifier.assertValid()
}
return -1