Re: [PATCH 2/7] submodule.c: convert is_submodule_modified to use strbuf_getwholeline_fd

2017-03-23 Thread Stefan Beller
On Thu, Mar 23, 2017 at 4:04 PM, Stefan Beller wrote: > > We could have had closing before the child finished before as well: > * the first read happens with strbuf_read(&buf, cp.out, 1024); The 1024 is only a hint. So it actually reads the output in full. So I guess I'll come up with a test for

Re: [PATCH 2/7] submodule.c: convert is_submodule_modified to use strbuf_getwholeline_fd

2017-03-23 Thread Stefan Beller
On Thu, Mar 23, 2017 at 3:50 PM, Jonathan Nieder wrote: > Stefan Beller wrote: > >> Instead of implementing line reading yet again, make use of our beautiful >> library functions. >> >> Signed-off-by: Stefan Beller >> --- >> submodule.c | 14 ++ >> 1 file changed, 2 insertions(+), 12

Re: [PATCH 2/7] submodule.c: convert is_submodule_modified to use strbuf_getwholeline_fd

2017-03-23 Thread Jonathan Nieder
Stefan Beller wrote: > Instead of implementing line reading yet again, make use of our beautiful > library functions. > > Signed-off-by: Stefan Beller > --- > submodule.c | 14 ++ > 1 file changed, 2 insertions(+), 12 deletions(-) This changes buffering behavior in two ways: - by u

[PATCH 2/7] submodule.c: convert is_submodule_modified to use strbuf_getwholeline_fd

2017-03-23 Thread Stefan Beller
Instead of implementing line reading yet again, make use of our beautiful library functions. Signed-off-by: Stefan Beller --- submodule.c | 14 ++ 1 file changed, 2 insertions(+), 12 deletions(-) diff --git a/submodule.c b/submodule.c index 2c667ac95a..c1b7b78260 100644 --- a/submod