From: Sverre Rabbelier Date: Mon, 04 Jul 2011 14:11:22 GMT Subject: Re: [PATCH v2 08/20] remote-curl: accept empty line as terminator Message-ID: In-Reply-To: <20110619224216.GF23893@elie> Heya, On Mon, Jun 20, 2011 at 00:42, Jonathan Nieder wrote: > Thanks.  I wonder if that first "if" should be something like > >        if (strbuf_getline(&buf, stdin, '\n') == EOF) { >                if (ferror(stdin)) >                        fprintf(stderr, "Error reading command stream\n"); >                else >                        fprintf(stderr, "Unexpected end of command stream\n"); >                return 1; >        } > > to catch I/O errors (e.g., the transport-helper exiting early). Good idea, done. Tests still pass too ;). -- Cheers, Sverre Rabbelier