Jeff King [off-list ref] writes:
Perhaps a better quest would be to eliminate all of those counts
entirely with code that is obviously correct. I think it is much more
readable to replace:
url = xmalloc(strlen(repo->base) + 64);
sprintf(url, "%s/objects/pack/pack-%s.idx", repo->base, hex);
with something like:
strbuf_init(&url);
strbuf_addf(&url, "%s/objects/pack/pack-%s.idx", repo->base, hex);
Ugh, this typically calls snprintf() twice doesn't it?