Cast to long for c++11.

[SVN r86693]