Commit 9fa4daec authored by Rusty Russell's avatar Rusty Russell Committed by Ben Hutchings

lguest: fix occasional crash in example launcher.

commit ca16f580 upstream.

We usually got away with ->next on the final entry being NULL, but it
finally bit me.
Signed-off-by: default avatarRusty Russell <rusty@rustcorp.com.au>
[bwh: Backported to 3.2: adjust filename]
Signed-off-by: default avatarBen Hutchings <ben@decadent.org.uk>
parent 601e4d67
......@@ -1299,6 +1299,7 @@ static struct device *new_device(const char *name, u16 type)
dev->feature_len = 0;
dev->num_vq = 0;
dev->running = false;
dev->next = NULL;
/*
* Append to device list. Prepending to a single-linked list is
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment