Exit code is between 0-255. So protect against VERY unlikey chance of overflow. (#2000)

This commit is contained in:
Chris Rankin 2017-11-06 11:54:48 +00:00 committed by GitHub
parent 00a9014852
commit 41e0be1958
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -52,6 +52,10 @@ if [ $abstractCount -gt 0 ]; then
fi
badChanges=$(($removalCount + $abstractCount))
if [ $badChanges -gt 255 ]; then
echo "OVERFLOW! Number of bad API changes: $badChanges"
badChanges=255
fi
echo "Exiting with exit code" $badChanges
exit $badChanges