seat: protect kmscon_seat_remove_display() correctly
We have to check for NULL pointers like all the other public entries do. Signed-off-by: David Herrmann <dh.herrmann@googlemail.com>
This commit is contained in:
parent
63298eb881
commit
dc1ac3d891
@ -809,6 +809,9 @@ void kmscon_seat_remove_display(struct kmscon_seat *seat,
|
||||
struct shl_dlist *iter;
|
||||
struct kmscon_display *d;
|
||||
|
||||
if (!seat || !disp)
|
||||
return;
|
||||
|
||||
shl_dlist_for_each(iter, &seat->displays) {
|
||||
d = shl_dlist_entry(iter, struct kmscon_display, list);
|
||||
if (d->disp != disp)
|
||||
|
Loading…
x
Reference in New Issue
Block a user