Added cast to silence compiler warning

Cast to (size_t) to silence warning about losing integer precision.