not having wide chars is soooo 90, please, I *really* don't care with
[apps/madmutt.git] / lib-crypt / pgpkey.c
index b31676a..d9e2de3 100644 (file)
 #include <lib-lib/ascii.h>
 #include <lib-lib/macros.h>
 #include <lib-lib/file.h>
+#include <lib-lib/debug.h>
 
 #include <lib-mime/mime.h>
 
+#include <lib-ui/curses.h>
+#include <lib-ui/enter.h>
+#include <lib-ui/menu.h>
+
 #include "mutt.h"
-#include "enter.h"
 #include "recvattach.h"
-#include "mutt_curses.h"
-#include "mutt_menu.h"
 #include "pgp.h"
 #include "pager.h"
 #include "sort.h"
 
-#include "lib/debug.h"
 
 #include <string.h>
 #include <ctype.h>
@@ -757,7 +758,7 @@ BODY *pgp_make_key_attachment (char *tempf)
   return att;
 }
 
-static LIST *pgp_add_string_to_hints (LIST * hints, const char *str)
+static string_list_t *pgp_add_string_to_hints (string_list_t * hints, const char *str)
 {
   char *scratch;
   char *t;
@@ -787,7 +788,7 @@ static pgp_key_t *pgp_get_lastp (pgp_key_t p)
 pgp_key_t pgp_getkeybyaddr (address_t * a, short abilities, pgp_ring_t keyring)
 {
   address_t *r, *p;
-  LIST *hints = NULL;
+  string_list_t *hints = NULL;
 
   int weak = 0;
   int invalid = 0;
@@ -811,7 +812,7 @@ pgp_key_t pgp_getkeybyaddr (address_t * a, short abilities, pgp_ring_t keyring)
   mutt_message (_("Looking for keys matching \"%s\"..."), a->mailbox);
   keys = pgp_get_candidates (keyring, hints);
 
-  mutt_free_list (&hints);
+  string_list_wipe(&hints);
 
   if (!keys)
     return NULL;
@@ -859,7 +860,7 @@ pgp_key_t pgp_getkeybyaddr (address_t * a, short abilities, pgp_ring_t keyring)
           this_key_has_weak = 1;
       }
 
-      address_delete (&r);
+      address_list_wipe(&r);
     }
 
     if (match && !this_key_has_strong && this_key_has_invalid)
@@ -905,7 +906,7 @@ pgp_key_t pgp_getkeybyaddr (address_t * a, short abilities, pgp_ring_t keyring)
 
 pgp_key_t pgp_getkeybystr (char *p, short abilities, pgp_ring_t keyring)
 {
-  LIST *hints = NULL;
+  string_list_t *hints = NULL;
   pgp_key_t keys;
   pgp_key_t matches = NULL;
   pgp_key_t *last = &matches;
@@ -917,7 +918,7 @@ pgp_key_t pgp_getkeybystr (char *p, short abilities, pgp_ring_t keyring)
 
   hints = pgp_add_string_to_hints (hints, p);
   keys = pgp_get_candidates (keyring, hints);
-  mutt_free_list (&hints);
+  string_list_wipe(&hints);
 
   if (!keys)
     return NULL;