Use line buffering so messages are flushed immediately