From: Junio C Hamano Date: Wed, 6 May 2015 04:00:36 +0000 (-0700) Subject: Merge branch 'mm/usage-log-l-can-take-regex' X-Git-Tag: v2.5.0-rc0~147 X-Git-Url: https://git.lorimer.id.au/gitweb.git/diff_plain/67498507699641549094f0cbf8800f88176b50c9?ds=inline;hp=-c Merge branch 'mm/usage-log-l-can-take-regex' Documentation fix. * mm/usage-log-l-can-take-regex: log -L: improve error message on malformed argument Documentation: change -L: to -L: --- 67498507699641549094f0cbf8800f88176b50c9 diff --combined Documentation/blame-options.txt index b299b59023,23b8ff80df..a09969ba08 --- a/Documentation/blame-options.txt +++ b/Documentation/blame-options.txt @@@ -4,13 -4,13 +4,13 @@@ --root:: Do not treat root commits as boundaries. This can also be - controlled via the `blame.showroot` config option. + controlled via the `blame.showRoot` config option. --show-stats:: Include additional statistics at the end of blame output. -L ,:: - -L ::: + -L ::: Annotate only the given line range. May be specified multiple times. Overlapping ranges are allowed. + diff --combined Documentation/git-log.txt index 18bc716a0c,6e65c5aa32..5692945a0b --- a/Documentation/git-log.txt +++ b/Documentation/git-log.txt @@@ -62,9 -62,9 +62,9 @@@ produced by `--stat`, etc output by allowing them to allocate space in advance. -L ,::: - -L :::: + -L :::: Trace the evolution of the line range given by "," - (or the funcname regex ) within the . You may + (or the function name regex ) within the . You may not give any pathspec limiters. This is currently limited to a walk starting from a single revision, i.e., you may only give zero or one positive revision arguments. @@@ -184,7 -184,7 +184,7 @@@ log.date: `--date` option.) Defaults to "default", which means to write dates like `Sat May 8 19:35:34 2010 -0500`. -log.showroot:: +log.showRoot:: If `false`, `git log` and related commands will not treat the initial commit as a big creation event. Any root commits in `git log -p` output would be shown without a diff attached. diff --combined line-log.c index b43ac58698,1a6bc5921b..a5ed9e3642 --- a/line-log.c +++ b/line-log.c @@@ -237,7 -237,7 +237,7 @@@ static void diff_ranges_release(struct range_set_release(&diff->target); } -void line_log_data_init(struct line_log_data *r) +static void line_log_data_init(struct line_log_data *r) { memset(r, 0, sizeof(struct line_log_data)); range_set_init(&r->ranges, 0); @@@ -575,7 -575,7 +575,7 @@@ parse_lines(struct commit *commit, cons name_part = skip_range_arg(item->string); if (!name_part || *name_part != ':' || !name_part[1]) - die("-L argument '%s' not of the form start,end:file", + die("-L argument not 'start,end:file' or ':funcname:file': %s", item->string); range_part = xstrndup(item->string, name_part - item->string); name_part++; @@@ -1099,7 -1099,6 +1099,7 @@@ static int process_all_files(struct lin rg->pair = diff_filepair_dup(queue->queue[i]); memcpy(&rg->diff, pairdiff, sizeof(struct diff_ranges)); } + free(pairdiff); } return changed;