Diffusion GnuPG c395f8315362

agent: Terminate pinentry process gracefully, by watching socket.

Authored by gniibe on Feb 19 2019, 6:36 AM.

Description

agent: Terminate pinentry process gracefully, by watching socket.

* agent/call-pinentry.c (watch_sock): New.
(do_getpin): Spawn the watching thread.

While we don't have npth_cancel (and it's difficult to implement it
correctly), this is a kind of best compromise allowing a thread's
polling when pinentry is active.

  • GnuPG-bug-id: T2011
  • Signed-off-by: NIIBE Yutaka <gniibe@fsij.org>