]> granicus.if.org Git - mutt/commitdiff
KeyTable is pgp_uid_t **, not pgp_key_t *. Fix some sizeof
authorThomas Roessler <roessler@does-not-exist.org>
Wed, 8 Oct 2003 19:55:39 +0000 (19:55 +0000)
committerThomas Roessler <roessler@does-not-exist.org>
Wed, 8 Oct 2003 19:55:39 +0000 (19:55 +0000)
statements accordingly.  Note that pgp_key_t is also a pointer,
though, so this should not have broken things.

pgpkey.c

index bb98403a3939b6bf5b01fe5463780e97fceeae56..77ec11e3da11b45c8f6c6133c9fc7accecc636a1 100644 (file)
--- a/pgpkey.c
+++ b/pgpkey.c
@@ -474,7 +474,7 @@ static pgp_key_t pgp_select_key (pgp_key_t keys,
       if (i == keymax)
       {
        keymax += 5;
-       safe_realloc (&KeyTable, sizeof (pgp_key_t) * keymax);
+       safe_realloc (&KeyTable, sizeof (pgp_uid_t *) * keymax);
       }
       
       KeyTable[i++] = a;
@@ -504,7 +504,7 @@ static pgp_key_t pgp_select_key (pgp_key_t keys,
       f = pgp_compare_trust;
       break;
   }
-  qsort (KeyTable, i, sizeof (pgp_key_t), f);
+  qsort (KeyTable, i, sizeof (pgp_uid_t *), f);
 
   helpstr[0] = 0;
   mutt_make_help (buf, sizeof (buf), _("Exit  "), MENU_PGP, OP_EXIT);