1
0
Fork 0

workspace: Clean structs using clear GSList utility function

Part-of: <https://gitlab.gnome.org/GNOME/mutter/-/merge_requests/3701>
This commit is contained in:
Marco Trevisan (Treviño) 2023-05-22 15:57:04 +02:00 committed by Marge Bot
parent e005d035c0
commit 44c6d02964

View file

@ -262,8 +262,7 @@ workspace_free_all_struts (MetaWorkspace *workspace)
if (workspace->all_struts == NULL)
return;
g_slist_free_full (workspace->all_struts, g_free);
workspace->all_struts = NULL;
g_clear_slist (&workspace->all_struts, g_free);
}
/**
@ -278,8 +277,7 @@ workspace_free_builtin_struts (MetaWorkspace *workspace)
if (workspace->builtin_struts == NULL)
return;
g_slist_free_full (workspace->builtin_struts, g_free);
workspace->builtin_struts = NULL;
g_clear_slist (&workspace->all_struts, g_free);
}
/* Ensure that the workspace is empty by making sure that