From 7d96017b4eacd337025aa27a18bdd3fa74c21097 Mon Sep 17 00:00:00 2001
From: Federico Lolli <federico.lolli@skywarder.eu>
Date: Sat, 11 May 2024 11:36:05 +0200
Subject: [PATCH] [ARP] Fix SMController binding with copy constructor

Removed it and passed by reference
---
 .../Groundstation/Automated/SMController/SMController.cpp | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)

diff --git a/src/boards/Groundstation/Automated/SMController/SMController.cpp b/src/boards/Groundstation/Automated/SMController/SMController.cpp
index 5c366cf4d..a5b34cd95 100644
--- a/src/boards/Groundstation/Automated/SMController/SMController.cpp
+++ b/src/boards/Groundstation/Automated/SMController/SMController.cpp
@@ -60,15 +60,15 @@ bool SMController::start()
     bool ok = true;
 
     // add the Propagator task
-    result = scheduler->addTask(bind(&Propagator::update, propagator),
+    result = scheduler->addTask(bind(&Propagator::update, &propagator),
                                 PropagatorConfig::PROPAGATOR_PERIOD,
                                 TaskScheduler::Policy::RECOVER);
     ok &= result == 0;
 
     // add the Follower task
-    size_t result = scheduler->addTask(bind(&Follower::update, follower),
-                                       FollowerConfig::FOLLOWER_PERIOD,
-                                       TaskScheduler::Policy::RECOVER);
+    result = scheduler->addTask(bind(&Follower::update, &follower),
+                                FollowerConfig::FOLLOWER_PERIOD,
+                                TaskScheduler::Policy::RECOVER);
     ok &= result == 0;
 
     // add the update task
-- 
GitLab