From: Daniel Kahn Gillmor <firstname.lastname@example.org>
Date: Tue, 1 Nov 2016 00:14:10 -0400
Subject: agent: Avoid tight timer tick when possible.
- agent/gpg-agent.c (need_tick): Evaluate whether the short-phase
handle_tick() is needed.
(handle_connections): On each cycle of the select loop, adjust whether
we should call handle_tick() or not.
- agent/call-scd.c (start_scd): Call interrupt_main_thread_loop() once
the scdaemon thread context has started up.
With this change, an idle gpg-agent that has no scdaemon running only
wakes up once a minute (to check_own_socket).
Signed-off-by: Daniel Kahn Gillmor <email@example.com>
agent/call-scd.c | 4 +++-
agent/gpg-agent.c | 25 ++++++++++++++++++++++++-
2 files changed, 27 insertions(+), 2 deletions(-)