summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorLibravatar Jeff King <peff@peff.net>2016-06-13 01:39:20 -0400
committerLibravatar Junio C Hamano <gitster@pobox.com>2016-06-13 10:33:14 -0700
commit7c4b169585ebe650783051c4b7a7b17de62836ad (patch)
treeb021308207ccf6ab7807b7f3941a2e595eca8cc2
parentparse_opt_string_list: stop allocating new strings (diff)
downloadtgif-7c4b169585ebe650783051c4b7a7b17de62836ad.tar.xz
interpret-trailers: don't duplicate option strings
There's no need to do so; the argv strings will last until the end of the program. Signed-off-by: Jeff King <peff@peff.net> Signed-off-by: Junio C Hamano <gitster@pobox.com>
-rw-r--r--builtin/interpret-trailers.c2
1 files changed, 1 insertions, 1 deletions
diff --git a/builtin/interpret-trailers.c b/builtin/interpret-trailers.c
index 46838d24a9..b75e953111 100644
--- a/builtin/interpret-trailers.c
+++ b/builtin/interpret-trailers.c
@@ -19,7 +19,7 @@ static const char * const git_interpret_trailers_usage[] = {
int cmd_interpret_trailers(int argc, const char **argv, const char *prefix)
{
int trim_empty = 0;
- struct string_list trailers = STRING_LIST_INIT_DUP;
+ struct string_list trailers = STRING_LIST_INIT_NODUP;
struct option options[] = {
OPT_BOOL(0, "trim-empty", &trim_empty, N_("trim empty trailers")),