mirror of
https://github.com/pavel-odintsov/fastnetmon
synced 2024-11-24 02:46:36 +01:00
Convert Debian 6 version to decimal point. Closes #382
This commit is contained in:
parent
a710ef3503
commit
464cacc907
@ -790,6 +790,12 @@ sub detect_distribution {
|
||||
|
||||
$distro_version = `cat /etc/debian_version`;
|
||||
chomp $distro_version;
|
||||
|
||||
# Debian 6 example: 6.0.10
|
||||
# We will try transform it to decimal number
|
||||
if ($distro_version =~ /^(\d+\.\d+)\.\d+$/) {
|
||||
$distro_version = $1;
|
||||
}
|
||||
} elsif ($issue_first_line =~ m/Ubuntu (\d+(?:\.\d+)?)/) {
|
||||
$distro_type = 'ubuntu';
|
||||
$distro_version = $1;
|
||||
|
Loading…
Reference in New Issue
Block a user