Fix potential stack overflow caused by integer overflow am: 1570b62c am: 5b4bf745 am: 6360e91b Change-Id: I1e23e75fd05e41b9cd31bb93b945135bef21c04f
mentioned in commit db0c360d
mentioned in commit ca7a1eab