convert bare readlink to strbuf_readlink
authorJeff King <peff@peff.net>
Mon, 25 May 2009 10:46:09 +0000 (06:46 -0400)
committerJunio C Hamano <gitster@pobox.com>
Mon, 25 May 2009 18:34:02 +0000 (11:34 -0700)
commit3cd7388d57db4f4a29949e8de96493fb77059484
treedfa546e4577ae9f13d6b2f7b18ddbb63b86e3a72
parent9619ff14159ab3401636b9883a715b0f20b051df
convert bare readlink to strbuf_readlink

This particular readlink call never NUL-terminated its
result, making it a potential source of bugs (though there
is no bug now, as it currently always respects the length
field). Let's just switch it to strbuf_readlink which is
shorter and less error-prone.

Signed-off-by: Jeff King <peff@peff.net>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
diff.c