aboutsummaryrefslogtreecommitdiff
path: root/revision.c
diff options
context:
space:
mode:
Diffstat (limited to 'revision.c')
-rw-r--r--revision.c4
1 files changed, 1 insertions, 3 deletions
diff --git a/revision.c b/revision.c
index 5826e5d59..24b89ebfd 100644
--- a/revision.c
+++ b/revision.c
@@ -1372,11 +1372,9 @@ static int handle_revision_opt(struct rev_info *revs, int argc, const char **arg
struct strbuf buf = STRBUF_INIT;
revs->show_notes = 1;
revs->show_notes_given = 1;
- if (!revs->notes_opt.extra_notes_refs)
- revs->notes_opt.extra_notes_refs = xcalloc(1, sizeof(struct string_list));
strbuf_addstr(&buf, arg+13);
expand_notes_ref(&buf);
- string_list_append(revs->notes_opt.extra_notes_refs,
+ string_list_append(&revs->notes_opt.extra_notes_refs,
strbuf_detach(&buf, NULL));
} else if (!strcmp(arg, "--no-notes")) {
revs->show_notes = 0;