Fixed minor casting problem to prevent complier warning.
Should have been in previous commit 63fa4bb.