From 673cbb3e81e63cac51e6d3cbcd7e84bd435843b0 Mon Sep 17 00:00:00 2001 From: Marcus Brinkmann Date: Mon, 26 May 2003 19:13:15 +0000 Subject: [PATCH] 2003-05-26 Marcus Brinkmann * recipient.c (gpgme_recipients_add_name_with_validity): Add one to buffer to allocate. --- gpgme/ChangeLog | 5 +++++ gpgme/recipient.c | 2 +- 2 files changed, 6 insertions(+), 1 deletion(-) diff --git a/gpgme/ChangeLog b/gpgme/ChangeLog index 623cf20..43561a4 100644 --- a/gpgme/ChangeLog +++ b/gpgme/ChangeLog @@ -1,3 +1,8 @@ +2003-05-26 Marcus Brinkmann + + * recipient.c (gpgme_recipients_add_name_with_validity): Add one + to buffer to allocate. + 2003-05-19 Marcus Brinkmann * verify.c (parse_new_sig): Fix ERRSIG case. diff --git a/gpgme/recipient.c b/gpgme/recipient.c index 51d4734..e592b4b 100644 --- a/gpgme/recipient.c +++ b/gpgme/recipient.c @@ -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; -- 2.26.2