mbeckerle commented on a change in pull request #539:
URL: https://github.com/apache/daffodil/pull/539#discussion_r620560033
##########
File path:
daffodil-tdml-processor/src/main/scala/org/apache/daffodil/tdml/processor/DaffodilTDMLDFDLProcessor.scala
##########
@@ -298,6 +298,13 @@ class DaffodilTDMLDFDLProcessor private (private var dp:
DataProcessor) extends
def doParseWithBothApis(dpInputStream: java.io.InputStream, saxInputStream:
java.io.InputStream,
lengthLimitInBits: Long): TDMLParseResult = {
+ //
+ // TDML Tests MUST have a length limit. Otherwise they cannot determine if
+ // there is left-over-data or not without doing more reading from the
input stream
+ // so as to be sure to hit end-of-data.
+ //
+ Assert.usage(lengthLimitInBits >= 0)
Review comment:
Done
--
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.
For queries about this service, please contact Infrastructure at:
[email protected]