summaryrefslogtreecommitdiff
path: root/src/core
diff options
context:
space:
mode:
authorPablo Barciela <[email protected]>2019-02-26 18:03:25 +0100
committerZenWalker <[email protected]>2019-03-06 12:01:56 +0100
commit58c6a2d7910feea665fb0f6a664e5091f19a8e2d (patch)
tree44b8e16c7f1f46cf59bf942977e058803b4fd66e /src/core
parent13f3a8b411e7588a0e6c4991a3ced554bedee0f3 (diff)
downloadmarco-58c6a2d7910feea665fb0f6a664e5091f19a8e2d.tar.bz2
marco-58c6a2d7910feea665fb0f6a664e5091f19a8e2d.tar.xz
screen: Fix use of memory after it is freed
Fixes Clang static analyzer warning: core/screen.c:754:16: warning: Use of memory after it is freed result = g_list_prepend (result, info); ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~
Diffstat (limited to 'src/core')
-rw-r--r--src/core/screen.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/core/screen.c b/src/core/screen.c
index c03530c2..e0e4e506 100644
--- a/src/core/screen.c
+++ b/src/core/screen.c
@@ -749,9 +749,8 @@ list_windows (MetaScreen *screen)
else
{
info->xwindow = children[i];
+ result = g_list_prepend (result, info);
}
-
- result = g_list_prepend (result, info);
}
if (children)