[gtk+] Cast the return value of g_array_free to void* before casting to char**



commit 0f120ea5101f9f47212b0afd583e9469187b1e0f
Author: Ting-Wei Lan <lantw src gnome org>
Date:   Sat Jan 9 17:24:12 2016 +0800

    Cast the return value of g_array_free to void* before casting to char**
    
    Let the compiler know that we don't want to use it as char*, so there is
    no alignment error.
    
    https://bugzilla.gnome.org/show_bug.cgi?id=760350
    https://bugzilla.gnome.org/show_bug.cgi?id=755659

 gtk/gtkactionmuxer.c |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
---
diff --git a/gtk/gtkactionmuxer.c b/gtk/gtkactionmuxer.c
index 643aeb3..d8edef0 100644
--- a/gtk/gtkactionmuxer.c
+++ b/gtk/gtkactionmuxer.c
@@ -138,7 +138,7 @@ gtk_action_muxer_list_actions (GActionGroup *action_group)
                             actions);
     }
 
-  return (gchar **) g_array_free (actions, FALSE);
+  return (gchar **)(void *) g_array_free (actions, FALSE);
 }
 
 static Group *


[Date Prev][Date Next]   [Thread Prev][Thread Next]   [Thread Index] [Date Index] [Author Index]