[Commits] utils.c 1.8 1.9

miras at claws-mail.org miras at claws-mail.org
Tue Nov 29 08:53:29 CET 2011


Update of /home/claws-mail/contacts/src
In directory claws-mail:/tmp/cvs-serv18713/src

Modified Files:
	utils.c 
Log Message:
2011-11-29 [mir]	0.6.0cvs31

	* src/utils.c
	* src/dbus/dbus-contact.h
	* src/dbus/server-object.c
	    Upgrade dbus part to handle attrib_def structure. 

Index: utils.c
===================================================================
RCS file: /home/claws-mail/contacts/src/utils.c,v
retrieving revision 1.8
retrieving revision 1.9
diff -u -d -r1.8 -r1.9
--- utils.c	28 Nov 2011 21:45:28 -0000	1.8
+++ utils.c	29 Nov 2011 07:53:27 -0000	1.9
@@ -1105,8 +1105,19 @@
 }
 
 void dbus_contact_print(DBusContact* contact, FILE* f) {
-	if (contact->data)
-		g_hash_table_foreach(contact->data, contact_data_print, f);
+    GHashTableIter iter;
+    gpointer key, value;
+    GHashTable* data;
+    
+	if (contact->data) {
+		data = hash_table_new();
+        g_hash_table_iter_init (&iter, contact->data);
+        while (g_hash_table_iter_next (&iter, &key, &value)) {
+            swap_data(data, key, value);
+        }
+        g_hash_table_foreach(data, contact_data_print, f);
+        hash_table_free(&data);   
+	}
 	if (contact->emails)
 		g_ptr_array_foreach(contact->emails, email_ptr_foreach, f);
 }



More information about the Commits mailing list