Don't cast free function passed to g_clear_pointer

The function is intentionally provided as macro to not require a
cast. Recently the macro was improved to check that the passed in
pointer matches the free function, so the cast to GDestroyNotify
is now even harmful.

https://gitlab.gnome.org/GNOME/mutter/merge_requests/176
This commit is contained in:
Florian Müllner
2018-07-23 19:22:51 +02:00
parent c403785d36
commit 7fdaf7721c
8 changed files with 22 additions and 22 deletions

View File

@ -931,9 +931,9 @@ meta_display_close (MetaDisplay *display,
g_clear_object (&display->gesture_tracker);
g_clear_pointer (&display->stack, (GDestroyNotify) meta_stack_free);
g_clear_pointer (&display->stack, meta_stack_free);
g_clear_pointer (&display->stack_tracker,
(GDestroyNotify) meta_stack_tracker_free);
meta_stack_tracker_free);
if (display->focus_timeout_id)
g_source_remove (display->focus_timeout_id);