use strbuf_addstr() instead of strbuf_addf() with "%s"
Call strbuf_addstr() for adding a simple string to a strbuf instead of using the heavier strbuf_addf(). This is shorter and documents the intent more clearly. Signed-off-by: Rene Scharfe <l.s.r@web.de> Signed-off-by: Junio C Hamano <gitster@pobox.com>
This commit is contained in:

committed by
Junio C Hamano

parent
02962d3684
commit
bc57b9c0cc
@ -112,7 +112,7 @@ static void remove_sequencer_state(void)
|
||||
{
|
||||
struct strbuf seq_dir = STRBUF_INIT;
|
||||
|
||||
strbuf_addf(&seq_dir, "%s", git_path(SEQ_DIR));
|
||||
strbuf_addstr(&seq_dir, git_path(SEQ_DIR));
|
||||
remove_dir_recursively(&seq_dir, 0);
|
||||
strbuf_release(&seq_dir);
|
||||
}
|
||||
|
Reference in New Issue
Block a user