[epiphany] password-manager: Fix crash in query_async_data_free()



commit 3e58ae2b2d716f3e9f3f34a1138f950efc041339
Author: Michael Catanzaro <mcatanzaro gnome org>
Date:   Sun Feb 23 13:39:57 2020 -0600

    password-manager: Fix crash in query_async_data_free()
    
    The async data structs are not zero-initialized. Oops!
    
    Fixes #1110

 lib/sync/ephy-password-manager.c | 6 +++---
 1 file changed, 3 insertions(+), 3 deletions(-)
---
diff --git a/lib/sync/ephy-password-manager.c b/lib/sync/ephy-password-manager.c
index fb809475e..51d03f3de 100644
--- a/lib/sync/ephy-password-manager.c
+++ b/lib/sync/ephy-password-manager.c
@@ -119,7 +119,7 @@ update_password_async_data_new (EphyPasswordManager *manager,
 {
   UpdatePasswordAsyncData *data;
 
-  data = g_new (UpdatePasswordAsyncData, 1);
+  data = g_new0 (UpdatePasswordAsyncData, 1);
   data->manager = g_object_ref (manager);
   data->password = g_strdup (password);
 
@@ -146,7 +146,7 @@ merge_passwords_async_data_new (EphyPasswordManager                    *manager,
 {
   MergePasswordsAsyncData *data;
 
-  data = g_new (MergePasswordsAsyncData, 1);
+  data = g_new0 (MergePasswordsAsyncData, 1);
   data->manager = g_object_ref (manager);
   data->is_initial = is_initial;
   data->remotes_deleted = remotes_deleted;
@@ -174,7 +174,7 @@ manage_record_async_data_new (EphyPasswordManager *manager,
 {
   ManageRecordAsyncData *data;
 
-  data = g_new (ManageRecordAsyncData, 1);
+  data = g_new0 (ManageRecordAsyncData, 1);
   data->manager = g_object_ref (manager);
   data->record = g_object_ref (record);
 


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