Use write() directly rather than std::cerr. This avoids mixing logs from
different threads.
Fix the build.
Merge pull request #436 from nomis52/master

Fix the mangled text when logging from multiple threads.
Fix the build.
Merge pull request #437 from nomis52/master

Fix the build.
Merge remote-tracking branch 'upstream/master'

Conflicts:
	common/base/Logging.cpp