From: Eric Sunshine Date: Tue, 23 Jul 2013 14:28:05 GMT Subject: [PATCH 2/5] t4211: demonstrate empty -L range crash Message-ID: <1374589688-27751-3-git-send-email-sunshine@sunshineco.com> In-Reply-To: <1374589688-27751-1-git-send-email-sunshine@sunshineco.com> Signed-off-by: Eric Sunshine --- t/t4211-line-log.sh | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/t/t4211-line-log.sh b/t/t4211-line-log.sh index 7776f93..1db1edd 100755 --- a/t/t4211-line-log.sh +++ b/t/t4211-line-log.sh @@ -64,4 +64,12 @@ test_bad_opts "-L 1,1000:b.c" "has only.*lines" test_bad_opts "-L :b.c" "argument.*not of the form" test_bad_opts "-L :foo:b.c" "no match" +# There is a separate bug when an empty -L range is the first -L encountered, +# thus to demonstrate this particular bug, the empty -L range must follow a +# non-empty -L range. +test_expect_failure '-L {empty-range} (any -L)' ' + n=$(expr $(cat b.c | wc -l) + 1) && + git log -L1,1:b.c -L$n:b.c +' + test_done -- 1.8.3.4.1120.gc240c48