[git] GnuPG - branch, master, updated. gnupg-2.1.17-43-g8d77490

by Werner Koch cvs at cvs.gnupg.org
Fri Jan 6 18:50:50 CET 2017


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  8d774904c8066d8c0f19cfffe2d568979bb8c470 (commit)
      from  e1f68337b979fe4b7c3bd095a83ea832e14efb74 (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 8d774904c8066d8c0f19cfffe2d568979bb8c470
Author: Werner Koch <wk at gnupg.org>
Date:   Fri Jan 6 18:45:14 2017 +0100

    agent,w32: Fix annoying output to DebugView.
    
    * agent/gpg-agent.c (startup_fd_list): Do not define for W32.
    (main) [W32]: Do not call get_all_open_fds.
    --
    
    GnuPG-bug-id: 2267
    Signed-off-by: Werner Koch <wk at gnupg.org>

diff --git a/agent/gpg-agent.c b/agent/gpg-agent.c
index f4ed6c5..724b55a 100644
--- a/agent/gpg-agent.c
+++ b/agent/gpg-agent.c
@@ -303,8 +303,10 @@ static int putty_support;
 #endif /*HAVE_W32_SYSTEM*/
 
 /* The list of open file descriptors at startup.  Note that this list
-   has been allocated using the standard malloc.  */
+ * has been allocated using the standard malloc.  */
+#ifndef HAVE_W32_SYSTEM
 static int *startup_fd_list;
+#endif
 
 /* The signal mask at startup and a flag telling whether it is valid.  */
 #ifdef HAVE_SIGPROCMASK
@@ -949,8 +951,10 @@ main (int argc, char **argv )
 
   /* Before we do anything else we save the list of currently open
      file descriptors and the signal mask.  This info is required to
-     do the exec call properly. */
+     do the exec call properly.  We don't need it on Windows.  */
+#ifndef HAVE_W32_SYSTEM
   startup_fd_list = get_all_open_fds ();
+#endif /*!HAVE_W32_SYSTEM*/
 #ifdef HAVE_SIGPROCMASK
   if (!sigprocmask (SIG_UNBLOCK, NULL, &startup_signal_mask))
     startup_signal_mask_valid = 1;
diff --git a/common/exechelp-w32.c b/common/exechelp-w32.c
index a7a6db3..e79ee5b 100644
--- a/common/exechelp-w32.c
+++ b/common/exechelp-w32.c
@@ -128,11 +128,14 @@ close_all_fds (int first, int *except)
 
 
 /* Returns an array with all currently open file descriptors.  The end
-   of the array is marked by -1.  The caller needs to release this
-   array using the *standard free* and not with xfree.  This allow the
-   use of this function right at startup even before libgcrypt has
-   been initialized.  Returns NULL on error and sets ERRNO
-   accordingly.  */
+ * of the array is marked by -1.  The caller needs to release this
+ * array using the *standard free* and not with xfree.  This allow the
+ * use of this function right at startup even before libgcrypt has
+ * been initialized.  Returns NULL on error and sets ERRNO
+ * accordingly.  Note that fstat prints a warning to DebugView for all
+ * invalid fds which is a bit annoying.  We actually do not need this
+ * function in real code (close_all_fds is a dummy anyway) but we keep
+ * it for use by t-exechelp.c.  */
 int *
 get_all_open_fds (void)
 {

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

Summary of changes:
 agent/gpg-agent.c     |  8 ++++++--
 common/exechelp-w32.c | 13 ++++++++-----
 2 files changed, 14 insertions(+), 7 deletions(-)


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




More information about the Gnupg-commits mailing list