Split input stream by newlines, also sending '0' closes the connection
Document client usage with netcat