TRQ-1900. Change a sprintf to a snprintf. Also remove the random adding of space for another char at the end of a buffer.
Merge branch '4.2-dev' of https://github.com/adaptivecomputing/torque into 4.2-dev