From 773b8384fa7ececcb9ad31aff4333e5ce3c6c4af Mon Sep 17 00:00:00 2001 From: Georges Basile Stavracas Neto Date: Sat, 17 Mar 2018 21:44:41 -0300 Subject: [PATCH] monitor-manager-kms: Don't add GPU if it fails This is a small mistake spotted while working on a solution for #77. When a GPU fails to initialize, we're adding them anyway, which might have pretty bad consequences when trying to use these NULL GPUs. Issue: #77 --- src/backends/native/meta-monitor-manager-kms.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/backends/native/meta-monitor-manager-kms.c b/src/backends/native/meta-monitor-manager-kms.c index 1a8be0855..3cee754d1 100644 --- a/src/backends/native/meta-monitor-manager-kms.c +++ b/src/backends/native/meta-monitor-manager-kms.c @@ -683,6 +683,7 @@ meta_monitor_manager_kms_initable_init (GInitable *initable, { g_warning ("Failed to open secondary gpu '%s': %s", gpu_path, secondary_error->message); + continue; } meta_monitor_manager_add_gpu (META_MONITOR_MANAGER (manager_kms),