mirror of
https://github.com/brl/mutter.git
synced 2024-11-25 01:20:42 -05:00
fix memory leak of group_windows, and don't use the variable name "tmp"
2002-10-17 Havoc Pennington <hp@redhat.com> * src/stack.c (apply_constraints): fix memory leak of group_windows, and don't use the variable name "tmp" twice. Shadow variables bad.
This commit is contained in:
parent
aa62466091
commit
3da0b1c7d9
@ -1,3 +1,9 @@
|
||||
2002-10-17 Havoc Pennington <hp@redhat.com>
|
||||
|
||||
* src/stack.c (apply_constraints): fix memory leak of
|
||||
group_windows, and don't use the variable name "tmp" twice. Shadow
|
||||
variables bad.
|
||||
|
||||
2002-10-17 Havoc Pennington <hp@redhat.com>
|
||||
|
||||
* src/tools/metacity-window-demo.c (dialog_cb): add code to create
|
||||
|
12
src/stack.c
12
src/stack.c
@ -436,7 +436,7 @@ apply_constraints (GList *list)
|
||||
w->type == META_WINDOW_UTILITY))
|
||||
{
|
||||
GSList *group_windows;
|
||||
GSList *tmp;
|
||||
GSList *tmp2;
|
||||
MetaGroup *group;
|
||||
|
||||
group = meta_window_get_group (w);
|
||||
@ -446,11 +446,11 @@ apply_constraints (GList *list)
|
||||
else
|
||||
group_windows = NULL;
|
||||
|
||||
tmp = group_windows;
|
||||
tmp2 = group_windows;
|
||||
|
||||
while (tmp != NULL)
|
||||
while (tmp2 != NULL)
|
||||
{
|
||||
MetaWindow *group_window = tmp->data;
|
||||
MetaWindow *group_window = tmp2->data;
|
||||
|
||||
if (!(meta_window_is_ancestor_of_transient (w, group_window)))
|
||||
{
|
||||
@ -459,8 +459,10 @@ apply_constraints (GList *list)
|
||||
ensure_above (w, group_window);
|
||||
}
|
||||
|
||||
tmp = tmp->next;
|
||||
tmp2 = tmp2->next;
|
||||
}
|
||||
|
||||
g_slist_free (group_windows);
|
||||
}
|
||||
else if (w->xtransient_for != None &&
|
||||
!w->transient_parent_is_root_window)
|
||||
|
Loading…
Reference in New Issue
Block a user