Also explicitly close the compressed stream handler

Or else some gzip exit handler blows up on Python 2.5. :)
Fix a log file formatting typo

Oops! Probably caused by coding in the bus and the
bus hitting a pothole while editing this string (really!). :)
Flush file handler right after dumping memory log to it

This seems to help with some compressed logging issues
(vim not being able to read the compressed log, zcat reporting
incorrect length).