changeset 29547:7be0dbc00168

Add purple_marshal_POINTER__POINTER(), which sadrul says should be used for the patch attached to #4598. Refs #4598.
author John Bailey <rekkanoryo@rekkanoryo.org>
date Sun, 07 Mar 2010 01:27:02 +0000
parents 537f8fd047c6
children 09f8ddb2f628
files libpurple/signals.c libpurple/signals.h
diffstat 2 files changed, 17 insertions(+), 0 deletions(-) [+]
line wrap: on
line diff
--- a/libpurple/signals.c	Sat Mar 06 21:38:42 2010 +0000
+++ b/libpurple/signals.c	Sun Mar 07 01:27:02 2010 +0000
@@ -1009,6 +1009,21 @@
 }
 
 void
+purple_marshal_POINTER__POINTER(
+                                    PurpleCallback cb, va_list args, void *data,
+                                    void **return_val)
+{
+	gpointer ret_val;
+	void *arg1 = va_arg(args, void *);
+
+	ret_val = ((gpointer(*)(void *, void *))cb)(arg1, data);
+
+	if (return_val != NULL)
+		*return_val = ret_val;
+}
+
+
+void
 purple_marshal_POINTER__POINTER_INT(
                                     PurpleCallback cb, va_list args, void *data,
                                     void **return_val)
--- a/libpurple/signals.h	Sat Mar 06 21:38:42 2010 +0000
+++ b/libpurple/signals.h	Sun Mar 07 01:27:02 2010 +0000
@@ -355,6 +355,8 @@
 void purple_marshal_BOOLEAN__INT_POINTER(
 		PurpleCallback cb, va_list args, void *data, void **return_val);
 
+void purple_marshal_POINTER__POINTER(
+		PurpleCallback cb, va_list args, void *data, void **return_val);
 void purple_marshal_POINTER__POINTER_INT(
 		PurpleCallback cb, va_list args, void *data, void **return_val);
 void purple_marshal_POINTER__POINTER_INT64(