[git] Pinentry - branch, master, updated. pinentry-0.9.1-22-g319e1a3

by Werner Koch cvs at cvs.gnupg.org
Mon May 11 10:54:04 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 standard pinentry collection".

The branch, master has been updated
       via  319e1a32e3ab67cb0624c0586d7519c16c76d43b (commit)
       via  3d02645d757e573e4628a1caf2e36bb92d523e77 (commit)
      from  1a8af55b76d8235ce891f44808064e7f846e193c (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 319e1a32e3ab67cb0624c0586d7519c16c76d43b
Author: Werner Koch <wk at gnupg.org>
Date:   Mon May 11 10:53:08 2015 +0200

    gtk: Use a description string from gpg-agent for libsecret.
    
    * pinentry/pinentry.h (struct pinentry): Add field default_pwmngr.
    * pinentry/pinentry.c (option_handler): Set it.
    * gtk+-2/pinentry-gtk-2.c (create_window) [HAVE_LIBSECRET]: Use new
    string.

diff --git a/gtk+-2/pinentry-gtk-2.c b/gtk+-2/pinentry-gtk-2.c
index 24d3a98..9d29f52 100644
--- a/gtk+-2/pinentry-gtk-2.c
+++ b/gtk+-2/pinentry-gtk-2.c
@@ -576,7 +576,15 @@ create_window (pinentry_t ctx, int confirm_mode)
     /* Only show this if we can cache passwords and we have a stable
        key identifier.  */
     {
-      w = gtk_check_button_new_with_label ("Save passphrase using libsecret");
+      if (pinentry->default_pwmngr)
+        {
+          msg = pinentry_utf8_validate (pinentry->default_pwmngr);
+          w = gtk_check_button_new_with_mnemonic (msg);
+          g_free (msg);
+        }
+      else
+        w = gtk_check_button_new_with_label ("Save passphrase using libsecret");
+
       gtk_box_pack_start (GTK_BOX (box), w, TRUE, FALSE, 0);
       gtk_widget_show (w);
 
diff --git a/pinentry/pinentry.c b/pinentry/pinentry.c
index 7b3fde5..16e634c 100644
--- a/pinentry/pinentry.c
+++ b/pinentry/pinentry.c
@@ -100,6 +100,7 @@ struct pinentry pinentry =
     NULL,        /* default_ok  */
     NULL,        /* default_cancel  */
     NULL,        /* default_prompt  */
+    NULL,        /* default_pwmngr  */
     0,           /* allow_external_password_cache.  */
     0,           /* tried_password_cached.  */
     NULL,        /* keyinfo  */
@@ -717,6 +718,12 @@ option_handler (ASSUAN_CONTEXT ctx, const char *key, const char *value)
       if (!pinentry.default_prompt)
 	return ASSUAN_Out_Of_Core;
     }
+  else if (!strcmp (key, "default-pwmngr"))
+    {
+      pinentry.default_pwmngr = strdup (value);
+      if (!pinentry.default_pwmngr)
+	return ASSUAN_Out_Of_Core;
+    }
   else if (!strcmp (key, "allow-external-password-cache") && !*value)
     {
       pinentry.allow_external_password_cache = 1;
diff --git a/pinentry/pinentry.h b/pinentry/pinentry.h
index 02f76a3..2b5ad27 100644
--- a/pinentry/pinentry.h
+++ b/pinentry/pinentry.h
@@ -148,6 +148,7 @@ struct pinentry
   char *default_ok;
   char *default_cancel;
   char *default_prompt;
+  char *default_pwmngr;
 
   /* Whether we are allowed to read the password from an external
      cache.  */

commit 3d02645d757e573e4628a1caf2e36bb92d523e77
Author: Werner Koch <wk at gnupg.org>
Date:   Mon May 11 10:51:34 2015 +0200

    gtk: Silence compiler warning

diff --git a/gtk+-2/pinentry-gtk-2.c b/gtk+-2/pinentry-gtk-2.c
index b154831..24d3a98 100644
--- a/gtk+-2/pinentry-gtk-2.c
+++ b/gtk+-2/pinentry-gtk-2.c
@@ -25,7 +25,14 @@
 #include "config.h"
 #endif
 #include <gdk/gdkkeysyms.h>
+#if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 7 )
+# pragma GCC diagnostic push
+# pragma GCC diagnostic ignored "-Wstrict-prototypes"
+#endif
 #include <gtk/gtk.h>
+#if __GNUC__ > 4 || (__GNUC__ == 4 && __GNUC_MINOR__ >= 7 )
+# pragma GCC diagnostic pop
+#endif
 #include <assert.h>
 #include <math.h>
 #include <stdio.h>

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

Summary of changes:
 gtk+-2/pinentry-gtk-2.c | 17 ++++++++++++++++-
 pinentry/pinentry.c     |  7 +++++++
 pinentry/pinentry.h     |  1 +
 3 files changed, 24 insertions(+), 1 deletion(-)


hooks/post-receive
-- 
The standard pinentry collection
http://git.gnupg.org




More information about the Gnupg-commits mailing list