[gtk+] Fix some compilation warnings
- From: Javier Jardón <jjardon src gnome org>
- To: svn-commits-list gnome org
- Cc:
- Subject: [gtk+] Fix some compilation warnings
- Date: Mon, 9 Nov 2009 09:28:17 +0000 (UTC)
commit f1f6d76078dccd1c7d7c305a45c270451ead6612
Author: Javier Jardón <jjardon gnome org>
Date: Mon Nov 9 10:27:30 2009 +0100
Fix some compilation warnings
Use the proper G*_TO_POINTER macro
gtk/tests/object.c | 6 +++---
1 files changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/gtk/tests/object.c b/gtk/tests/object.c
index f0af1d3..4b77e93 100644
--- a/gtk/tests/object.c
+++ b/gtk/tests/object.c
@@ -181,15 +181,15 @@ value_as_pointer (GValue *value)
if (g_value_fits_pointer (value))
return g_value_peek_pointer (value);
if (G_VALUE_HOLDS_BOOLEAN (value))
- return (void*) g_value_get_boolean (value);
+ return GINT_TO_POINTER(g_value_get_boolean (value));
if (G_VALUE_HOLDS_CHAR (value))
return (void*) (gssize) g_value_get_char (value);
if (G_VALUE_HOLDS_UCHAR (value))
return (void*) (gsize) g_value_get_uchar (value);
if (G_VALUE_HOLDS_INT (value))
- return (void*) g_value_get_int (value);
+ return GINT_TO_POINTER(g_value_get_int (value));
if (G_VALUE_HOLDS_UINT (value))
- return (void*) g_value_get_uint (value);
+ return GUINT_TO_POINTER(g_value_get_uint (value));
if (G_VALUE_HOLDS_LONG (value))
return (void*) g_value_get_long (value);
if (G_VALUE_HOLDS_ULONG (value))
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]