Skip to content

Commit 6f5ecad

Browse files
chriscoolgitster
authored andcommitted
perf/aggregate: fix checking ENV{GIT_PERF_SUBSECTION}
The way we check ENV{GIT_PERF_SUBSECTION} could trigger comparison between undef and "" that may be flagged by use of strict & warnings. Let's fix that. Signed-off-by: Christian Couder <chriscool@tuxfamily.org> Signed-off-by: Junio C Hamano <gitster@pobox.com>
1 parent 5d445f3 commit 6f5ecad

1 file changed

Lines changed: 1 addition & 1 deletion

File tree

t/perf/aggregate.perl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ sub format_times {
7070
}
7171

7272
my $resultsdir = "test-results";
73-
if ($ENV{GIT_PERF_SUBSECTION} ne "") {
73+
if (exists $ENV{GIT_PERF_SUBSECTION} and $ENV{GIT_PERF_SUBSECTION} ne "") {
7474
$resultsdir .= "/" . $ENV{GIT_PERF_SUBSECTION};
7575
}
7676

0 commit comments

Comments
 (0)