[seahorse/wip/nielsdg/fix-warnings: 4/4] pgp: LdapSource: Don't declare keydata as const



commit c25782a46affd6104b77c448f4948fff976830f8
Author: Niels De Graef <nielsdegraef gmail com>
Date:   Mon Jan 13 08:47:37 2020 +0100

    pgp: LdapSource: Don't declare keydata as const
    
    Gets rid of a mismatched pointer warning.

 pgp/seahorse-ldap-source.c | 8 ++++----
 1 file changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/pgp/seahorse-ldap-source.c b/pgp/seahorse-ldap-source.c
index 64537ae9..415fc4ee 100644
--- a/pgp/seahorse-ldap-source.c
+++ b/pgp/seahorse-ldap-source.c
@@ -1022,24 +1022,24 @@ import_send_key (SeahorseLDAPSource *self, GTask *task)
     char *values[2];
     g_autoptr(GSource) gsource = NULL;
     GError *error = NULL;
-    const char *keydata;
+    char *keydata;
     int ldap_op;
     int rc;
 
     if (closure->current_index >= 0) {
-        keydata = closure->keydatas->pdata[closure->current_index];
+        keydata = g_ptr_array_index (closure->keydatas, closure->current_index);
         seahorse_progress_end (cancellable, keydata);
     }
 
     closure->current_index++;
 
     /* All done, complete operation */
-    if (closure->current_index == (int)closure->keydatas->len) {
+    if (closure->current_index == (int) closure->keydatas->len) {
         g_task_return_boolean (task, TRUE);
         return;
     }
 
-    keydata = closure->keydatas->pdata[closure->current_index];
+    keydata = g_ptr_array_index (closure->keydatas, closure->current_index);
     seahorse_progress_begin (cancellable, keydata);
     values[0] = keydata;
     values[1] = NULL;


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