Fix decimal mod overflow check.

Change-Id: Ieb74cf05e491078a7acc2ac118587fdaef3f38a6
Reviewed-on: http://gerrit.sjc.cloudera.com:8080/4435
Reviewed-by: Alex Behm <alex.behm@cloudera.com>
Tested-by: jenkins