Fixed issue with splice on perl versions > 5.23
Addressed error message: Experimental splice on scalar is now forbidden
This commit is contained in:
@@ -414,8 +414,8 @@ foreach my $d (@DNSDomain) {
|
||||
if ($d eq '!') { $d = $cgi->virtual_host; }
|
||||
elsif ($d eq '?') { $d = $cgi->param('domain'); }
|
||||
elsif ($d =~ /-?\d+/) {
|
||||
if ($d <0) { $d = join('.', splice([ split(/\./, $cgi->virtual_host) ], $d)); }
|
||||
else { $d = join('.', splice([ split(/\./, $host) ], ($d) ? -$d : 1)); }
|
||||
if ($d <0) { $d = join('.', splice(@{[ split(/\./, $cgi->virtual_host) ]}, $d)); }
|
||||
else { $d = join('.', splice(@{[ split(/\./, $host) ]}, ($d) ? -$d : 1)); }
|
||||
}
|
||||
$dnsdomain = $d if ($host && length($host) == length($d)+rindex($host,$d));
|
||||
last if $dnsdomain;
|
||||
|
||||
Reference in New Issue
Block a user