Use std::string rather than c-style buffers.

Refs #8924
Convert all line endings to UNIX style for git SHA1.

Refs #8924