logging: add a LogHandler::flush() call