From ab4dc1636ca044313b3ebc78bbf35e30d00a6986 Mon Sep 17 00:00:00 2001 From: Simon Ser Date: Tue, 14 Apr 2020 15:01:57 +0200 Subject: backend/multi: add backends at end of list This allows wlr_multi_for_each_backend to iterate on the backends in the order where they have been added. --- backend/multi/backend.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/multi/backend.c b/backend/multi/backend.c index 50851109..7ba25ca8 100644 --- a/backend/multi/backend.c +++ b/backend/multi/backend.c @@ -183,7 +183,7 @@ bool wlr_multi_backend_add(struct wlr_backend *_multi, wlr_log(WLR_ERROR, "Could not add backend: allocation failed"); return false; } - wl_list_insert(&multi->backends, &sub->link); + wl_list_insert(multi->backends.prev, &sub->link); sub->backend = backend; sub->container = &multi->backend; -- cgit v1.2.3