2003-05-26 Marcus Brinkmann <marcus@g10code.de>
authorMarcus Brinkmann <mb@g10code.com>
Mon, 26 May 2003 19:13:15 +0000 (19:13 +0000)
committerMarcus Brinkmann <mb@g10code.com>
Mon, 26 May 2003 19:13:15 +0000 (19:13 +0000)
* recipient.c (gpgme_recipients_add_name_with_validity): Add one
to buffer to allocate.

gpgme/ChangeLog
gpgme/recipient.c

index 623cf203b34968d35d9c86f3858b22f654905331..43561a46c164e6987b3d9a5d602079f139d199b6 100644 (file)
@@ -1,3 +1,8 @@
+2003-05-26  Marcus Brinkmann  <marcus@g10code.de>
+
+       * recipient.c (gpgme_recipients_add_name_with_validity): Add one
+       to buffer to allocate.
+
 2003-05-19  Marcus Brinkmann  <marcus@g10code.de>
 
        * verify.c (parse_new_sig): Fix ERRSIG case.
index 51d47345e4bffc1635eb90682a73247f6adbc4f0..e592b4b999f6dc645e9eccc157a29c7668fd30a7 100644 (file)
@@ -69,7 +69,7 @@ gpgme_recipients_add_name_with_validity (gpgme_recipients_t rset,
 
   if (!name || !rset)
     return GPGME_Invalid_Value;
-  uid = malloc (sizeof (*uid) + strlen (name));
+  uid = malloc (sizeof (*uid) + strlen (name) + 1);
   if (!uid)
     return GPGME_Out_Of_Core;
   uid->validity = validity;