[libgnome-keyring] Fix gnome_keyring_item_info_copy()



commit 4df8de140cd1b5941e19aee098101d2569cfa444
Author: Martin Pitt <martin pitt ubuntu com>
Date:   Sat Jan 14 11:53:41 2012 +0100

    Fix gnome_keyring_item_info_copy()
    
    Actually copy the values from the original instead of from the to-be-created
    copy.

 library/gnome-keyring-utils.c |    4 ++--
 1 files changed, 2 insertions(+), 2 deletions(-)
---
diff --git a/library/gnome-keyring-utils.c b/library/gnome-keyring-utils.c
index c0013d4..ed8629e 100644
--- a/library/gnome-keyring-utils.c
+++ b/library/gnome-keyring-utils.c
@@ -467,8 +467,8 @@ gnome_keyring_item_info_copy (GnomeKeyringItemInfo *item_info)
 	copy = g_new (GnomeKeyringItemInfo, 1);
 	memcpy (copy, item_info, sizeof (GnomeKeyringItemInfo));
 
-	copy->display_name = g_strdup (copy->display_name);
-	copy->secret = egg_secure_strdup (copy->secret);
+	copy->display_name = g_strdup (item_info->display_name);
+	copy->secret = egg_secure_strdup (item_info->secret);
 
 	return copy;
 }



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