Subject: bug#17337: epg-wait-for-status hangs forever

From: Stefan Monnier <[email-masked]>
Date: Wed, 14 May 2014 13:01:30 -0400

>     (while (and (eq (process-status (epg-context-process context)) 'run)
> 		epg-pending-status-list)
>       (accept-process-output (epg-context-process context) 1))

> This means that either (1) epg does not exit when it should, or
> (2) epg-pending-status-list doesn't become nil, which AFAIU means
> that no output is ever received from epg, or (3) accept-process-output
> gets stuck, even though it is called with a 1-sec time-out.

FWIW, I recently saw a hang when opening a foo.gpg file (it hung before
asking me for the passphrase).  I was in a hurry and had no time to dig
much further into the Elisp code to track down the problem, so I swiftly
switched to an xterm and did "gpg --use-agent foo.gpg" to decrypt the
file, and that hung as well.  Apparently it was some kind of
communication with the agent.

        Stefan