[ https://issues.apache.org/jira/browse/PIG-2951?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
Ashutosh Chauhan updated PIG-2951: ---------------------------------- Attachment: pig-2951.patch Here is the patch which does runtime checking for overflows/underflows and throws exception in case it detects overflows/underflows. I followed CMU's CERT Oracle Secure Coding Standard for Java https://www.securecoding.cert.org/confluence/display/java/NUM00-J.+Detect+or+prevent+integer+overflow for this. Hopefully, extra CPU cycles it will incur aren't too many. > Overflow, Underflow errors > -------------------------- > > Key: PIG-2951 > URL: https://issues.apache.org/jira/browse/PIG-2951 > Project: Pig > Issue Type: Bug > Components: impl > Affects Versions: 0.0.0, 0.1.0, 0.2.0, 0.3.0, 0.4.0, 0.5.0, 0.6.0, 0.7.0, > 0.8.0, 0.8.1, 0.9.0, 0.9.1, 0.9.2, 0.10.0 > Reporter: Ashutosh Chauhan > Assignee: Ashutosh Chauhan > Attachments: pig-2951.patch > > > With very large (or very small) integer values there is a possibility of > overflow (or underflow) errors. Worse thing is instead of failing, this > currently results in incorrect results being returned, thereby leaving user > with no clue that some of the tuples may have wrong value. -- This message is automatically generated by JIRA. If you think it was sent incorrectly, please contact your JIRA administrators For more information on JIRA, see: http://www.atlassian.com/software/jira