[metacity] menu: fix cast-function-type warnings
- From: Alberts Muktupāvels <muktupavels src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [metacity] menu: fix cast-function-type warnings
- Date: Wed, 12 Sep 2018 11:56:01 +0000 (UTC)
commit 7c4f2cca6bbea95d69461f701cc10df58d77c5ba
Author: Alberts Muktupāvels <alberts muktupavels gmail com>
Date: Sun Sep 2 14:02:46 2018 +0300
menu: fix cast-function-type warnings
src/ui/menu.c | 11 +++++++++--
1 file changed, 9 insertions(+), 2 deletions(-)
---
diff --git a/src/ui/menu.c b/src/ui/menu.c
index 48212310..7d946e18 100644
--- a/src/ui/menu.c
+++ b/src/ui/menu.c
@@ -280,6 +280,13 @@ menu_item_new (MenuItem *menuitem, int workspace_id)
return mi;
}
+static void
+free_menu_data (MenuData *menu_data,
+ GClosure *closure)
+{
+ g_free (menu_data);
+}
+
MetaWindowMenu*
meta_window_menu_new (MetaFrames *frames,
MetaMenuOp ops,
@@ -398,7 +405,7 @@ meta_window_menu_new (MetaFrames *frames,
"activate",
G_CALLBACK (activate_cb),
md,
- (GClosureNotify) g_free, 0);
+ (GClosureNotify) free_menu_data, 0);
gtk_menu_shell_append (GTK_MENU_SHELL (submenu), submi);
@@ -425,7 +432,7 @@ meta_window_menu_new (MetaFrames *frames,
"activate",
G_CALLBACK (activate_cb),
md,
- (GClosureNotify) g_free, 0);
+ (GClosureNotify) free_menu_data, 0);
}
if (mi)
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]