mirror of
https://github.com/brl/mutter.git
synced 2024-11-25 09:30:45 -05:00
monitor-manager-kms: Use g_autoptr for error
A minor code cleanup.
This commit is contained in:
parent
a5fd9a6e2f
commit
de294f34bb
@ -674,7 +674,7 @@ meta_monitor_manager_kms_initable_init (GInitable *initable,
|
|||||||
gpu_paths = get_gpu_paths (manager_kms, GPU_TYPE_SECONDARY, primary_gpu_path);
|
gpu_paths = get_gpu_paths (manager_kms, GPU_TYPE_SECONDARY, primary_gpu_path);
|
||||||
for (l = gpu_paths; l; l = l->next)
|
for (l = gpu_paths; l; l = l->next)
|
||||||
{
|
{
|
||||||
GError *secondary_error = NULL;
|
g_autoptr (GError) secondary_error = NULL;
|
||||||
char *gpu_path = l->data;
|
char *gpu_path = l->data;
|
||||||
MetaGpuKms *gpu_kms;
|
MetaGpuKms *gpu_kms;
|
||||||
|
|
||||||
@ -683,7 +683,6 @@ meta_monitor_manager_kms_initable_init (GInitable *initable,
|
|||||||
{
|
{
|
||||||
g_warning ("Failed to open secondary gpu '%s': %s",
|
g_warning ("Failed to open secondary gpu '%s': %s",
|
||||||
gpu_path, secondary_error->message);
|
gpu_path, secondary_error->message);
|
||||||
g_error_free (secondary_error);
|
|
||||||
}
|
}
|
||||||
|
|
||||||
meta_monitor_manager_add_gpu (META_MONITOR_MANAGER (manager_kms),
|
meta_monitor_manager_add_gpu (META_MONITOR_MANAGER (manager_kms),
|
||||||
|
Loading…
Reference in New Issue
Block a user