Commit a116022e authored by Junio C Hamano's avatar Junio C Hamano

Merge branch 'sb/branch-avoid-repeated-strbuf-release' into maint

* sb/branch-avoid-repeated-strbuf-release:
  branch: reset instead of release a strbuf
parents 4bf90c17 a9155c50
......@@ -216,7 +216,7 @@ static int delete_branches(int argc, const char **argv, int force, int kinds,
if (!head_rev)
die(_("Couldn't look up commit object for HEAD"));
}
for (i = 0; i < argc; i++, strbuf_release(&bname)) {
for (i = 0; i < argc; i++, strbuf_reset(&bname)) {
char *target = NULL;
int flags = 0;
......@@ -281,8 +281,9 @@ static int delete_branches(int argc, const char **argv, int force, int kinds,
}
free(name);
strbuf_release(&bname);
return(ret);
return ret;
}
static int calc_maxwidth(struct ref_array *refs, int remote_bonus)
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment