Fix MSVC warning.

Added explicit typecast.