Merge branch 'jk/tag-sort'
[gitweb.git] / http-walker.c
index ab6a4febebc9d06c83354779a5439bf756fb973f..dbddfaa1773265a2917d4715158f16845d7139e5 100644 (file)
@@ -341,8 +341,7 @@ static void fetch_alternates(struct walker *walker, const char *base)
        if (walker->get_verbosely)
                fprintf(stderr, "Getting alternates list for %s\n", base);
 
-       url = xmalloc(strlen(base) + 31);
-       sprintf(url, "%s/objects/info/http-alternates", base);
+       url = xstrfmt("%s/objects/info/http-alternates", base);
 
        /*
         * Use a callback to process the result, since another request