ref-filter: drop sprintf and strcpy calls
commita5e03bf5c686e9f2da5e94e091e0ea531d40c6b8
authorJeff King <peff@peff.net>
Thu, 24 Sep 2015 21:07:12 +0000 (24 17:07 -0400)
committerJunio C Hamano <gitster@pobox.com>
Fri, 25 Sep 2015 17:18:18 +0000 (25 10:18 -0700)
tree3301349bacac312861f43322e2d05545c5d90c5e
parent9ae97018fb2e7f30ab92fdc2965d1dcff2c5c296
ref-filter: drop sprintf and strcpy calls

The ref-filter code comes from for-each-ref, and inherited a
number of raw sprintf and strcpy calls. These are generally
all safe, as we custom-size the buffers, or are formatting
numbers into sufficiently large buffers. But we can make the
resulting code even simpler and more obviously correct by
using some of our helper functions.

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