Fixed GCC warning on narrowing conversion

Stops compilation on linux/GCC