[git] GnuPG - branch, master, updated. gnupg-2.1.8-68-gce2a84b

by NIIBE Yutaka cvs at cvs.gnupg.org
Tue Oct 6 00:53:19 CEST 2015


This is an automated email from the git hooks/post-receive script. It was
generated because a ref change was pushed to the repository containing
the project "The GNU Privacy Guard".

The branch, master has been updated
       via  ce2a84b58833fd308d5fe11756721f39c953280a (commit)
      from  f3959f14b6c496c726bbca5230becb7b6844a234 (commit)

Those revisions listed above that are new to this repository have
not appeared on any other notification email; so we list those
revisions in full, below.

- Log -----------------------------------------------------------------
commit ce2a84b58833fd308d5fe11756721f39c953280a
Author: NIIBE Yutaka <gniibe at fsij.org>
Date:   Tue Oct 6 02:05:04 2015 +0900

    agent: Fix non-allocation for pinentry_loopback.
    
    * agent/call-pinentry.c (agent_get_passphrase): Don't allocate, it will
    be allocated by pinentry_loopback.

diff --git a/agent/call-pinentry.c b/agent/call-pinentry.c
index 9845a03..0140387 100644
--- a/agent/call-pinentry.c
+++ b/agent/call-pinentry.c
@@ -1063,12 +1063,10 @@ agent_get_passphrase (ctrl_t ctrl,
         {
 	  size_t size;
 	  size_t len = ASSUAN_LINELENGTH/2;
-	  unsigned char *buffer = gcry_malloc_secure (len);
+	  unsigned char *buffer;
 
 	  rc = pinentry_loopback(ctrl, "PASSPHRASE", &buffer, &size, len);
-	  if (rc)
-	    xfree(buffer);
-	  else
+	  if (!rc)
 	    {
 	      buffer[size] = 0;
 	      *retpass = buffer;

-----------------------------------------------------------------------

Summary of changes:
 agent/call-pinentry.c | 6 ++----
 1 file changed, 2 insertions(+), 4 deletions(-)


hooks/post-receive
-- 
The GNU Privacy Guard
http://git.gnupg.org




More information about the Gnupg-commits mailing list