use strbuf_addstr() for adding strings to strbufs

Use strbuf_addstr() instead of strbuf_addf() for adding strings.  That's
simpler and makes the intent clearer.

Patch generated by Coccinelle and contrib/coccinelle/strbuf.cocci;
adjusted indentation in refs/packed-backend.c manually.

Signed-off-by: Rene Scharfe <l.s.r@web.de>
Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:
René Scharfe
2017-10-01 16:44:20 +02:00
committed by Junio C Hamano
parent fa2bb34477
commit 72d4a9a721
3 changed files with 4 additions and 4 deletions

View File

@ -203,7 +203,7 @@ int sequencer_remove_state(struct replay_opts *opts)
free(opts->xopts[i]);
free(opts->xopts);
strbuf_addf(&dir, "%s", get_dir(opts));
strbuf_addstr(&dir, get_dir(opts));
remove_dir_recursively(&dir, 0);
strbuf_release(&dir);