Skip to content
Snippets Groups Projects
Commit b9cbc5e5 authored by Vladimir Sedach's avatar Vladimir Sedach
Browse files

In yield, made wait-list notification happen after other-thread computation is aborted.

parent 03124802
No related branches found
No related tags found
No related merge requests found
......@@ -30,12 +30,12 @@ computation of the future)."
(if (slot-boundp future 'values)
(return-from force nil)
(setf (%values future) values)))
(dolist (x (wait-list future))
(with-lock-held ((car x))
(condition-notify (cdr x))))
(with-slots (computing-thread) future
(unless (eq computing-thread (current-thread))
(abort-scheduled-future-task computing-thread (future-id future)))
(dolist (x (wait-list future))
(with-lock-held ((car x))
(condition-notify (cdr x))))
(setf computing-thread nil
(wait-list future) nil
(task future) nil
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment