fix for duration index

This commit is contained in:
Radu Ioan Fericean
2015-07-16 20:08:43 +03:00
parent e462f2051d
commit cd8d42fc68

View File

@@ -104,7 +104,7 @@ func (s *Session) debitLoop(runIdx int) {
nextCd.TimeEnd = cc.GetEndTime() // set debited timeEnd
// update call duration with real debited duration
nextCd.DurationIndex -= debitPeriod
nextCd.DurationIndex += nextCd.GetDuration()
nextCd.DurationIndex += cc.GetDuration()
nextCd.MaxCostSoFar += cc.Cost
time.Sleep(cc.GetDuration())
index++