wizard97 / ArduinoProcessScheduler

An Arduino object oriented process scheduler designed to replace them all
46 stars 16 forks source link

compiling failed when EXCEPTION_HANDLING is enabled #9

Open MartinSE73 opened 7 years ago

MartinSE73 commented 7 years ago

I want to use the functionalitiy of the timeout handling for long running processes (Webbino). For this I have to activate the _PROCESS_EXCEPTION_HANDLING and _PROCESS_TIMEOUT_INTERRUPTS. But when I uncomment the EXCEPTION_HANDLING I receive following compiler error:

_C:\Users\Martin\Documents\Arduino\Heat2017\HT2017\libraries\Arduino_Process_Scheduler\src\ProcessScheduler\Scheduler.cpp: In member function 'virtual void Scheduler::handleException(Process*, int)':

C:\Users\Martin\Documents\Arduino\Heat2017\HT2017\libraries\Arduino_Process_Scheduler\src\ProcessScheduler\Scheduler.cpp:464:21: error: request for member 'restart' in 'process', which is of pointer type 'Process*' (maybe you meant to use '->' ?)

         process.restart();_

Now my quetion is it a "layer 8 problem" or a bug?

wizard97 commented 7 years ago

Hi Martin,

This is indeed a simple bug, recently changed the default behavior to restart a stuck process and accidentally used . instead of -> on a pointer type. Fixed in master, should be good now, give it a try and let me know.