summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorAlberts Muktupāvels <alberts.muktupavels@gmail.com>2018-09-02 13:55:52 +0300
committerAlberts Muktupāvels <alberts.muktupavels@gmail.com>2018-09-02 13:55:52 +0300
commit3e1a3f3000b6db6fe05a51d637264ebe8d14708e (patch)
tree79308052f440f6f9b282da39af64df5f3b94b09d
parent05fcc25f2c6224af6db0a858f6e33dbde79d3813 (diff)
downloadmetacity-3e1a3f3000b6db6fe05a51d637264ebe8d14708e.tar.gz
edge-resistance: fix cast-function-type warning
-rw-r--r--src/core/edge-resistance.c8
1 files changed, 1 insertions, 7 deletions
diff --git a/src/core/edge-resistance.c b/src/core/edge-resistance.c
index 4bab4a1b..105c51b3 100644
--- a/src/core/edge-resistance.c
+++ b/src/core/edge-resistance.c
@@ -1105,13 +1105,7 @@ compute_resistance_and_snapping_edges (MetaDisplay *display)
g_list_free (stacked_windows);
/* Free the memory used by the obscuring windows/docks lists */
g_slist_free (window_stacking);
- /* FIXME: Shouldn't there be a helper function to make this one line of code
- * to free a list instead of four ugly ones?
- */
- g_slist_foreach (obscuring_windows,
- (void (*)(gpointer,gpointer))&g_free, /* ew, for ugly */
- NULL);
- g_slist_free (obscuring_windows);
+ g_slist_free_full (obscuring_windows, g_free);
/* Sort the list. FIXME: Should I bother with this sorting? I just
* sort again later in cache_edges() anyway...