Patch 840

see #840

this fixes additional  minor issues like additional docblock comments and an unused variable in `LogWriter::write()`.