[PATCH v4 4/5] branch.c: replace `git_config()` with `git_config_get_string()

2014-07-30 Thread Tanay Abhra
Use `git_config_get_string()` instead of `git_config()` to take advantage of the config-set API which provides a cleaner control flow. Signed-off-by: Tanay Abhra tanay...@gmail.com --- branch.c | 24 1 file changed, 4 insertions(+), 20 deletions(-) diff --git a/branch.c

Re: [PATCH v4 4/5] branch.c: replace `git_config()` with `git_config_get_string()

2014-07-30 Thread Matthieu Moy
Tanay Abhra tanay...@gmail.com writes: int read_branch_desc(struct strbuf *buf, const char *branch_name) { - struct branch_desc_cb cb; + char *v = NULL; struct strbuf name = STRBUF_INIT; strbuf_addf(name, branch.%s.description, branch_name); - cb.config_name =