projects
/
model-checker.git
/ blobdiff
commit
grep
author
committer
pickaxe
?
search:
re
summary
|
shortlog
|
log
|
commit
|
commitdiff
|
tree
raw
| inline |
side by side
schedule: set thread to NULL when there is no next thread
[model-checker.git]
/
schedule.c
diff --git
a/schedule.c
b/schedule.c
index f5ce644810856b06b3002996a1d95c1e11f17b9d..a4613c597f95d3362888df1ba6051fbbb1d75a58 100644
(file)
--- a/
schedule.c
+++ b/
schedule.c
@@
-32,8
+32,10
@@
static void enqueue_thread(struct thread *t)
static int dequeue_thread(struct thread **t)
{
- if (!head)
+ if (!head) {
+ *t = NULL;
return -1;
+ }
*t = head->this;
head->live = 0;
if (head == tail)