Small bug/style fixes, logfile & console output