Avoid invalid ranges.
Signed-off-by: Nicolás Ortega Froysa <nicolas@ortegas.org>
This commit is contained in:
parent
e6514c37d3
commit
8a62fc9064
@ -125,6 +125,9 @@ $n, $tx->{action}, $tx->{pkg_name}
|
||||
foreach my $i (@sel) {
|
||||
if ($i =~ /^[0-9]+-[0-9]+$/) {
|
||||
my ($start, $end) = $i =~ /^([0-9]+)-([0-9]+)$/;
|
||||
if ($start >= $end) {
|
||||
die("Invalid range: $start-$end\n");
|
||||
}
|
||||
push(@sel, ($start..$end));
|
||||
}
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user