Fixed issue with int long casting