1
0
Fork 0

lguest: fix occasional crash in example launcher.

We usually got away with ->next on the final entry being NULL, but it
finally bit me.

Signed-off-by: Rusty Russell <rusty@rustcorp.com.au>
Cc: stable@kernel.org
hifive-unleashed-5.1
Rusty Russell 2012-10-04 12:03:25 +09:30
parent bb8111086c
commit ca16f580a5
1 changed files with 1 additions and 0 deletions

View File

@ -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