NATIVE-13, fix a overflow issue