strbuf.c: remove unnecessary strbuf_grow() from strbuf_getwholeline()

This use of strbuf_grow() is a historical artifact that was once used to ensure that strbuf.buf was allocated and properly nul-terminated. This was added before the introduction of the slopbuf in b315c5c0, which guarantees that strbuf.buf always points to a usable nul-terminated string. So let's remove it. Signed-off-by: Brandon Casey <drafnel@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>

Brandon Casey committed Oct 5, 2011 at 23:21 UTC 1844f8d591340bb43e4990c96afd0aba424adf48
1 file changed -1
strbuf.c
-1
@@ -357,7 +357,6 @@ int strbuf_getwholeline(struct strbuf *sb, FILE *fp, int term)
357 {
358 int ch;
359
360 - strbuf_grow(sb, 0);
360 if (feof(fp))
361 return EOF;
362