diff --git a/consumer/speed_controller.go b/consumer/speed_controller.go index 6ac46cb..ed3469a 100644 --- a/consumer/speed_controller.go +++ b/consumer/speed_controller.go @@ -55,6 +55,7 @@ func (c *fanControl) StartControl() { case <-ticker: go c.applyFanspeed(pastFanSpeedList, newFanSpeedList) pastFanSpeedList, newFanSpeedList = newFanSpeedList, make([]int, c.processorCount) + copy(newFanSpeedList, pastFanSpeedList) case changedSpeed := <-c.fanSpeedConsumer: newFanSpeedList[changedSpeed.Id] = changedSpeed.FanSpeed case <-c.handler.Done():