HPCC-12128 - MP connections take too long

Improve timeout loop when random numbers are equal, minor updates4

Signed-off-by: Mark Kelly <mark.kelly@lexisnexis.com>