[evolution-data-server] camel-imapx-utils: fixed capability registration function



commit 870ce1fe5aeb484001e6395c6aa55ac427791307
Author: Christian Hilberg <chilberg src gnome org>
Date:   Thu Jul 19 20:47:23 2012 +0200

    camel-imapx-utils: fixed capability registration function

 camel/camel-imapx-utils.c |   15 ++++++++-------
 1 files changed, 8 insertions(+), 7 deletions(-)
---
diff --git a/camel/camel-imapx-utils.c b/camel/camel-imapx-utils.c
index cc3feb8..9fc871a 100644
--- a/camel/camel-imapx-utils.c
+++ b/camel/camel-imapx-utils.c
@@ -476,8 +476,8 @@ imapx_register_capability (const gchar *capability)
 {
 	guint32 capa_id = 0;
 	guint64 check_id = 0;
-	GList *keys = NULL;
-	GList *tmp_keys = NULL;
+	GList *vals = NULL;
+	GList *tmp_vals = NULL;
 
 	g_return_val_if_fail (capability != NULL, 0);
 
@@ -493,14 +493,15 @@ imapx_register_capability (const gchar *capability)
 		goto exit;
 
 	/* not yet there, find biggest flag so far */
-	keys = g_hash_table_get_keys (capa_htable);
-	tmp_keys = keys;
-	while (tmp_keys != NULL) {
-		guint32 tmp_id = GPOINTER_TO_UINT (tmp_keys->data);
+	vals = g_hash_table_get_values (capa_htable);
+	tmp_vals = vals;
+	while (tmp_vals != NULL) {
+		guint32 tmp_id = GPOINTER_TO_UINT (tmp_vals->data);
 		if (capa_id < tmp_id)
 			capa_id = tmp_id;
-		tmp_keys = g_list_next (tmp_keys);
+		tmp_vals = g_list_next (tmp_vals);
 	}
+	g_list_free (vals);
 
 	/* shift-left biggest-so-far, sanity-check */
 	check_id = (capa_id << 1);



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