stevedlawrence commented on code in PR #988:
URL: https://github.com/apache/daffodil/pull/988#discussion_r1138641206
##########
daffodil-runtime1/src/main/scala/org/apache/daffodil/runtime1/processors/parsers/BlobLengthParsers.scala:
##########
@@ -55,9 +55,9 @@ trait ByteChunkWriter { self: PrimParser =>
remainingBitsToGet -= bitsToGet
} else {
val remainingBits =
- if (dis.remainingBits.isDefined) {
+ if (dis.remainingLimitedBits.isDefined) {
val totalBitsRead = nBits - remainingBitsToGet
- MaybeULong(dis.remainingBits.get + totalBitsRead)
+ MaybeULong(dis.remainingLimitedBits.get + totalBitsRead)
Review Comment:
> In this case, it is doing more than reporting an error, so I decided to
leave the functionality as-is.
I think it is reporting an error, it's just using slightly fancier logic to
take into account read data since the blob parsers reads data in chunks.
--
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.
To unsubscribe, e-mail: [email protected]
For queries about this service, please contact Infrastructure at:
[email protected]