CTest: Fix integer overflow when uploading huge files

When uploading files greater 2GB a cast to 'int' overflows, leading to a
bad alloc when passed to new. Also avoid floating point arithmetic when
integer calculations will work as well.

Reported-by: Justin Borodinsky <justin.borodinsky@gmail.com>
cmCTest: Use size_t for cmsysBase64_Encode return value
Merge topic 'base64-casts' into next

0bdd4ebf cmCTest: Use size_t for cmsysBase64_Encode return value
a9fae8ac CTest: Fix integer overflow when uploading huge files