[git] GPA - branch, master, updated. gpa-0.9.4-39-g63592f5

by Werner Koch cvs at cvs.gnupg.org
Tue Jul 1 10:13:41 CEST 2014


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 Assistant".

The branch, master has been updated
       via  63592f5afe2e4415bb3962b87bf461d56c099aed (commit)
      from  6e65e5c676fcc8ba4035dbe9b97c0769e2d3eb40 (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 63592f5afe2e4415bb3962b87bf461d56c099aed
Author: Werner Koch <wk at gnupg.org>
Date:   Wed Jun 25 14:33:34 2014 +0200

    Add option --verbose and silence some diagnostics.
    
    * src/gpa.c (verbose): New.
    (option_entries): Add option --verbose.
    * src/server.c (gpa_check_server): Print some diagnostics only in
    verbose mode.

diff --git a/src/gpa.c b/src/gpa.c
index 1ff0c5e..73335bd 100644
--- a/src/gpa.c
+++ b/src/gpa.c
@@ -60,6 +60,9 @@ gboolean disable_ticker;
 /* True if the gpgme edit FSM shall output debug messages.  */
 gboolean debug_edit_fsm;
 
+/* True if verbose messages are requested.  */
+gboolean verbose;
+
 /* Local variables.  */
 typedef struct
 {
@@ -99,7 +102,7 @@ static void print_version (void);
 /* All command line options of the main application.  */
 static GOptionEntry option_entries[] =
   {
-    { "version", 'v', G_OPTION_FLAG_NO_ARG, G_OPTION_ARG_CALLBACK,
+    { "version", 'V', G_OPTION_FLAG_NO_ARG, G_OPTION_ARG_CALLBACK,
       (gpointer) &print_version,
       N_("Output version information and exit"), NULL, },
     { "keyring", 'k', 0, G_OPTION_ARG_NONE, &args.start_key_manager,
@@ -127,6 +130,8 @@ static GOptionEntry option_entries[] =
     /* Note:  the cms option will eventually be removed.  */
     { "cms", 'x', G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE,
       &cms_hack, NULL, NULL },
+    { "verbose", 'v',      G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE,
+      &verbose,  NULL, NULL },
     { "disable-ticker", 0, G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE,
       &disable_ticker, NULL, NULL },
     { "debug-edit-fsm", 0, G_OPTION_FLAG_HIDDEN, G_OPTION_ARG_NONE,
diff --git a/src/gpa.h b/src/gpa.h
index b21a0d0..56583fa 100644
--- a/src/gpa.h
+++ b/src/gpa.h
@@ -53,6 +53,7 @@ extern gchar *gnupg_homedir;
 extern gboolean cms_hack;
 extern gboolean disable_ticker;
 extern gboolean debug_edit_fsm;
+extern gboolean verbose;
 
 /* Show the keyring editor dialog.  */
 void gpa_open_key_manager (GtkAction *action, void *data);
diff --git a/src/server.c b/src/server.c
index 023eaf8..c7c7740 100644
--- a/src/server.c
+++ b/src/server.c
@@ -2082,8 +2082,9 @@ gpa_check_server (void)
                                  gpgme_get_dirinfo ("uiserver-socket"), 0, 0);
   if (err)
     {
-      g_message ("error connecting an UI server: %s - %s",
-                 gpg_strerror (err), "assuming not running");
+      if (verbose || gpg_err_code (err) != GPG_ERR_ASS_CONNECT_FAILED)
+        g_message ("error connecting an UI server: %s - %s",
+                   gpg_strerror (err), "assuming not running");
       result = 0;
       goto leave;
     }
@@ -2100,7 +2101,8 @@ gpa_check_server (void)
 
   if (name_check)
     {
-      g_message ("an instance of this program is already running");
+      if (verbose)
+        g_message ("an instance of this program is already running");
       result = 2;
     }
   else

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

Summary of changes:
 src/gpa.c    |    7 ++++++-
 src/gpa.h    |    1 +
 src/server.c |    8 +++++---
 3 files changed, 12 insertions(+), 4 deletions(-)


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




More information about the Gnupg-commits mailing list