From: Marcus Brinkmann Date: Wed, 5 Mar 2008 19:58:41 +0000 (+0000) Subject: 2008-03-05 Marcus Brinkmann X-Git-Tag: gpgme-1.2.0@1385~78 X-Git-Url: http://git.tremily.us/?a=commitdiff_plain;h=eedb685d6a3a7fd27b340e4825bdf3fea79ae025;p=gpgme.git 2008-03-05 Marcus Brinkmann * decrypt.c (release_op_data): Release OPD->result.recipients. * encrypt.c (release_op_data): Release invalid_recipient. --- diff --git a/trunk/gpgme/ChangeLog b/trunk/gpgme/ChangeLog index 2a5c719..8285ff8 100644 --- a/trunk/gpgme/ChangeLog +++ b/trunk/gpgme/ChangeLog @@ -1,3 +1,8 @@ +2008-03-05 Marcus Brinkmann + + * decrypt.c (release_op_data): Release OPD->result.recipients. + * encrypt.c (release_op_data): Release invalid_recipient. + 2008-02-15 Marcus Brinkmann * engine-gpgconf.c (gpgconf_read): Fix end-of-line handline. diff --git a/trunk/gpgme/decrypt.c b/trunk/gpgme/decrypt.c index 5ce21ba..66250b1 100644 --- a/trunk/gpgme/decrypt.c +++ b/trunk/gpgme/decrypt.c @@ -50,12 +50,20 @@ static void release_op_data (void *hook) { op_data_t opd = (op_data_t) hook; + gpgme_recipient_t recipient = opd->result.recipients; if (opd->result.unsupported_algorithm) free (opd->result.unsupported_algorithm); if (opd->result.file_name) free (opd->result.file_name); + + while (recipient) + { + gpgme_recipient_t next = recipient->next; + free (recipient); + recipient = next; + } } diff --git a/trunk/gpgme/encrypt.c b/trunk/gpgme/encrypt.c index a7a1f4d..4744090 100644 --- a/trunk/gpgme/encrypt.c +++ b/trunk/gpgme/encrypt.c @@ -53,6 +53,7 @@ release_op_data (void *hook) gpgme_invalid_key_t next = invalid_recipient->next; if (invalid_recipient->fpr) free (invalid_recipient->fpr); + free (invalid_recipient); invalid_recipient = next; } }