mbeckerle commented on a change in pull request #433:
URL: https://github.com/apache/incubator-daffodil/pull/433#discussion_r504810993
##########
File path:
daffodil-runtime1/src/main/scala/org/apache/daffodil/processors/parsers/HexBinaryLengthParsers.scala
##########
@@ -36,6 +36,9 @@ sealed abstract class HexBinaryLengthParser(override val
context: ElementRuntime
val nBits = getLengthInBits(start).toInt
if (nBits == 0) {
currentElement.setDataValue(zeroLengthArray)
+ } else if (nBits < 0) {
+ // Integer overflow occurred, recommend using blob instead of hexBinary
+ PE(start, "Data is too large for xs:hexBinary. Consider using blobs
instead:
https://cwiki.apache.org/confluence/display/DAFFODIL/Proposal%3A+Binary+Large+Objects")
Review comment:
If you want to include a link, we should create an Apache short link
that can be kept up to date.
I just created: https://s.apache.org/daffodil-blob-feature for this if we
want to keep the link.
----------------------------------------------------------------
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]