[Pkg-gnupg-commit] [gnupg2] 02/03: adopt suggestion from gniibe related to #841143

Daniel Kahn Gillmor dkg at fifthhorseman.net
Wed Jan 18 08:23:34 UTC 2017


This is an automated email from the git hooks/post-receive script.

dkg pushed a commit to branch master
in repository gnupg2.

commit 65a2dbc55114258c34c6b53ebb4c30d58cfbb240
Author: Daniel Kahn Gillmor <dkg at fifthhorseman.net>
Date:   Wed Jan 18 03:12:27 2017 -0500

    adopt suggestion from gniibe related to #841143
---
 .../0003-agent-Avoid-tight-timer-tick-when-possible.patch | 15 +++++++++------
 ...t-Avoid-scheduled-checks-on-socket-when-inotify-.patch |  4 ++--
 2 files changed, 11 insertions(+), 8 deletions(-)

diff --git a/debian/patches/gpg-agent-idling/0003-agent-Avoid-tight-timer-tick-when-possible.patch b/debian/patches/gpg-agent-idling/0003-agent-Avoid-tight-timer-tick-when-possible.patch
index c1d8ee0..1732387 100644
--- a/debian/patches/gpg-agent-idling/0003-agent-Avoid-tight-timer-tick-when-possible.patch
+++ b/debian/patches/gpg-agent-idling/0003-agent-Avoid-tight-timer-tick-when-possible.patch
@@ -17,8 +17,8 @@ wakes up once a minute (to check_own_socket).
 Signed-off-by: Daniel Kahn Gillmor <dkg at fifthhorseman.net>
 ---
  agent/call-scd.c  |  4 +++-
- agent/gpg-agent.c | 25 ++++++++++++++++++++++++-
- 2 files changed, 27 insertions(+), 2 deletions(-)
+ agent/gpg-agent.c | 28 +++++++++++++++++++++++++++-
+ 2 files changed, 30 insertions(+), 2 deletions(-)
 
 diff --git a/agent/call-scd.c b/agent/call-scd.c
 index ba59c1825..1ac0f6ba5 100644
@@ -36,10 +36,10 @@ index ba59c1825..1ac0f6ba5 100644
    xfree (abs_homedir);
    if (err)
 diff --git a/agent/gpg-agent.c b/agent/gpg-agent.c
-index 04a775c9b..1bfe0f3ae 100644
+index 04a775c9b..92907210d 100644
 --- a/agent/gpg-agent.c
 +++ b/agent/gpg-agent.c
-@@ -2267,6 +2267,26 @@ create_directories (void)
+@@ -2267,6 +2267,29 @@ create_directories (void)
  }
  
  
@@ -58,6 +58,9 @@ index 04a775c9b..1bfe0f3ae 100644
 +  /* if scdaemon is running, we need to check that it's alive */
 +  if (agent_scd_check_running ())
 +    return 1;
++  /* if a shutdown was requested, we wait all connections closing.  */
++  if (shutdown_pending)
++    return 1;
 +  /* otherwise, nothing fine-grained to do. */
 +  return 0;
 +#endif /*HAVE_W32_SYSTEM*/
@@ -66,7 +69,7 @@ index 04a775c9b..1bfe0f3ae 100644
  
  /* This is the worker for the ticker.  It is called every few seconds
     and may only do fast operations. */
-@@ -2325,7 +2345,7 @@ agent_sigusr2_action (void)
+@@ -2325,7 +2348,7 @@ agent_sigusr2_action (void)
  
  #ifndef HAVE_W32_SYSTEM
  /* The signal handler for this program.  It is expected to be run in
@@ -75,7 +78,7 @@ index 04a775c9b..1bfe0f3ae 100644
  static void
  handle_signal (int signo)
  {
-@@ -2872,6 +2892,9 @@ handle_connections (gnupg_fd_t listen_fd,
+@@ -2872,6 +2895,9 @@ handle_connections (gnupg_fd_t listen_fd,
           thus a simple assignment is fine to copy the entire set.  */
        read_fdset = fdset;
  
diff --git a/debian/patches/gpg-agent-idling/0004-agent-Avoid-scheduled-checks-on-socket-when-inotify-.patch b/debian/patches/gpg-agent-idling/0004-agent-Avoid-scheduled-checks-on-socket-when-inotify-.patch
index 6a565ea..a1b902c 100644
--- a/debian/patches/gpg-agent-idling/0004-agent-Avoid-scheduled-checks-on-socket-when-inotify-.patch
+++ b/debian/patches/gpg-agent-idling/0004-agent-Avoid-scheduled-checks-on-socket-when-inotify-.patch
@@ -12,10 +12,10 @@ Signed-off-by: Daniel Kahn Gillmor <dkg at fifthhorseman.net>
  1 file changed, 2 insertions(+)
 
 diff --git a/agent/gpg-agent.c b/agent/gpg-agent.c
-index 1bfe0f3ae..0e5354947 100644
+index 92907210d..6bd0c3b57 100644
 --- a/agent/gpg-agent.c
 +++ b/agent/gpg-agent.c
-@@ -2894,6 +2894,8 @@ handle_connections (gnupg_fd_t listen_fd,
+@@ -2897,6 +2897,8 @@ handle_connections (gnupg_fd_t listen_fd,
  
        /* avoid a fine-grained timer if we don't need one: */
        timertbl[0].interval.tv_sec = need_tick () ? TIMERTICK_INTERVAL : 0;

-- 
Alioth's /usr/local/bin/git-commit-notice on /srv/git.debian.org/git/pkg-gnupg/gnupg2.git



More information about the Pkg-gnupg-commit mailing list