From 1738c88b35054163bcebafba0f3e4f5b5e703f5b Mon Sep 17 00:00:00 2001 From: Nigel Kukard <nkukard@lbsd.net> Date: Sun, 1 Dec 2013 09:44:13 +0000 Subject: [PATCH] Make sure we setup the stats ID's in tcstats --- opentrafficshaper/plugins/tcstats/tcstats.pm | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) diff --git a/opentrafficshaper/plugins/tcstats/tcstats.pm b/opentrafficshaper/plugins/tcstats/tcstats.pm index b47e001..811e21d 100644 --- a/opentrafficshaper/plugins/tcstats/tcstats.pm +++ b/opentrafficshaper/plugins/tcstats/tcstats.pm @@ -236,7 +236,7 @@ sub task_child_stdout # Check if this is a limit class... if (opentrafficshaper::plugins::tc::isTcLimitClass($interface,1,$stat->{'_class_child'})) { if (defined(my $lid = opentrafficshaper::plugins::tc::getLIDFromTcLimitClass($interface,$stat->{'_class_child'}))) { - $sid = opentrafficshaper::plugins::statistics::getSIDFromLID($lid); + $sid = opentrafficshaper::plugins::statistics::setSIDFromLID($lid); $direction = opentrafficshaper::plugins::statistics::getTrafficDirection($lid,$interface); } else { $logger->log(LOG_WARN,"[TCSTATS] Limit traffic class '%s:%s' NOT FOUND",$stat->{'_class_parent'},$stat->{'_class_child'}); @@ -245,11 +245,11 @@ sub task_child_stdout # Class = 1 is the root if ($classChildDec == 1) { # This is a special case case - $sid = opentrafficshaper::plugins::statistics::getSIDFromCID($interface,0); + $sid = opentrafficshaper::plugins::statistics::setSIDFromCID($interface,0); } else { # Save the class with the decimal number if (my $classID = opentrafficshaper::plugins::tc::getCIDFromTcLimitClass($interface,1,$stat->{'_class_child'})) { - $sid = opentrafficshaper::plugins::statistics::getSIDFromCID($interface,$classID); + $sid = opentrafficshaper::plugins::statistics::setSIDFromCID($interface,$classID); } else { $logger->log(LOG_WARN,"[TCSTATS] System traffic class '%s:%s' NOT FOUND",$stat->{'_class_parent'},$stat->{'_class_child'}); } -- GitLab