Welcome to mirror list, hosted at ThFree Co, Russian Federation.

git.kernel.org/pub/scm/git/git.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorNguyễn Thái Ngọc Duy <pclouds@gmail.com>2018-09-21 18:57:34 +0300
committerJunio C Hamano <gitster@pobox.com>2018-09-21 19:51:18 +0300
commit80e03855413c7ac3727df572d44131656e467426 (patch)
tree87514672fd2398022cfe062d97c3a470c9e1399c /line-log.c
parentacd00ea04998ce469d1775c658134b097e18f5a3 (diff)
line-range.c: remove implicit dependency on the_index
Signed-off-by: Nguyễn Thái Ngọc Duy <pclouds@gmail.com> Signed-off-by: Junio C Hamano <gitster@pobox.com>
Diffstat (limited to 'line-log.c')
-rw-r--r--line-log.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/line-log.c b/line-log.c
index 35adf199a5..d1d429d738 100644
--- a/line-log.c
+++ b/line-log.c
@@ -574,7 +574,7 @@ parse_lines(struct repository *r, struct commit *commit,
long begin = 0, end = 0;
long anchor;
- name_part = skip_range_arg(item->string);
+ name_part = skip_range_arg(item->string, r->index);
if (!name_part || *name_part != ':' || !name_part[1])
die("-L argument not 'start,end:file' or ':funcname:file': %s",
item->string);
@@ -599,7 +599,7 @@ parse_lines(struct repository *r, struct commit *commit,
if (parse_range_arg(range_part, nth_line, &cb_data,
lines, anchor, &begin, &end,
- full_name))
+ full_name, r->index))
die("malformed -L argument '%s'", range_part);
if ((!lines && (begin || end)) || lines < begin)
die("file %s has only %lu lines", name_part, lines);