cdew / omnithreadlibrary

Automatically exported from code.google.com/p/omnithreadlibrary
0 stars 0 forks source link

task.Terminated does not work as expected #3

Closed GoogleCodeExporter closed 9 years ago

GoogleCodeExporter commented 9 years ago
Instead of 'if task.Terminated' use

if WaitForSingleObject(task.TerminateEvent, 0) = WAIT_OBJECT_0 then

I do agree that this is my problem - bad object interface. Terminated 
signals whether the task has been fully stopped, not whether it should 
terminate.

Original issue reported on code.google.com by gabr42 on 1 Nov 2008 at 9:41

GoogleCodeExporter commented 9 years ago
*** Breaking interface change ***
- IOmniTask.Terminated renamed to IOmniTask.Stopped.
- New IOmniTask.Terminated that check whether the task *has been requested to 
terminate*.

Original comment by gabr42 on 1 Nov 2008 at 11:29