Skip to content

Commit 9f9fa9e

Browse files
author
dave
committed
#25 minor fix for running task on some platforms, tested on all units
1 parent d13672c commit 9f9fa9e

File tree

2 files changed

+2
-2
lines changed

2 files changed

+2
-2
lines changed

src/TaskManagerIO.cpp

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -169,7 +169,7 @@ void TaskManager::cancelTask(taskid_t taskId) {
169169
void TaskManager::yieldForMicros(uint32_t microsToWait) {
170170
yield();
171171

172-
auto& prevTask = runningTask;
172+
auto* prevTask = getRunningTask();
173173
unsigned long microsStart = micros();
174174
do {
175175
runLoop();

src/TaskManagerIO.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -287,7 +287,7 @@ class TaskManager {
287287
* store this pointer.
288288
* @return a temporary pointer to the running task that lasts as long as it is running.
289289
*/
290-
const tm_internal::TimerTaskAtomicPtr& getRunningTask() { return runningTask; }
290+
TimerTask* getRunningTask() { return runningTask; }
291291

292292
private:
293293
/**

0 commit comments

Comments
 (0)