Ver Fonte

- remove Smartmatch is experimental at warning
- bugfix: fixed mistake in traffic report sub

root há 4 anos atrás
pai
commit
c24e77bb66

+ 1 - 1
html/inc/common.php

@@ -122,7 +122,7 @@ function fbytes($traff)
         "T"
     );
     $KB = 1024;
-    if (!empty($traff) and $traf > 0) {
+    if (!empty($traff) and $traff > 0) {
         $index = min(((int) log($traff, $KB)), count($units) - 1);
         $result = round($traff / pow($KB, $index), 3) . ' ' . $units[$index] . 'b';
     } else {

+ 1 - 0
scripts/Rstat/cmd.pm

@@ -6,6 +6,7 @@ package Rstat::cmd;
 
 use utf8;
 use strict;
+no warnings qw( experimental);
 use English;
 use FindBin '$Bin';
 use lib "$Bin";

+ 1 - 0
scripts/Rstat/config.pm

@@ -7,6 +7,7 @@ package Rstat::config;
 use utf8;
 use strict;
 use English;
+no warnings qw( experimental);
 use FindBin '$Bin';
 use lib "$Bin";
 use base 'Exporter';

+ 1 - 0
scripts/Rstat/main.pm

@@ -7,6 +7,7 @@ package Rstat::main;
 use utf8;
 use strict;
 use English;
+no warnings qw( experimental);
 use FindBin '$Bin';
 use lib "$Bin";
 use base 'Exporter';

+ 1 - 0
scripts/Rstat/mysql.pm

@@ -7,6 +7,7 @@ package Rstat::mysql;
 use utf8;
 use strict;
 use English;
+no warnings qw( experimental);
 use FindBin '$Bin';
 use lib "$Bin";
 use base 'Exporter';

+ 1 - 0
scripts/Rstat/net_utils.pm

@@ -6,6 +6,7 @@ package Rstat::net_utils;
 
 use utf8;
 use strict;
+no warnings qw( experimental);
 use English;
 use FindBin qw($Bin);
 use lib "$Bin";

+ 1 - 0
scripts/Rstat/snmp.pm

@@ -8,6 +8,7 @@ use utf8;
 use strict;
 use English;
 use FindBin '$Bin';
+no warnings qw( experimental);
 use lib "$Bin";
 use base 'Exporter';
 use vars qw(@EXPORT @ISA);

+ 1 - 0
scripts/check_dhcp_pool.pl

@@ -8,6 +8,7 @@ use utf8;
 use English;
 use base;
 use FindBin '$Bin';
+no warnings qw( experimental);
 use lib "$Bin/";
 use strict;
 use DBI;

+ 4 - 0
scripts/set_port_descr.pl

@@ -21,6 +21,10 @@ use Rstat::snmp;
 use Rstat::cmd;
 use Net::SNMP qw(:snmp);
 use Fcntl qw(:flock);
+
+no warnings qw( experimental);
+
+
 open(SELF,"<",$0) or die "Cannot open $0 - $!";
 flock(SELF, LOCK_EX|LOCK_NB) or exit 1;