gnome3: Honor timeout.
* gnome3/pinentry-gnome3.c (create_prompt): Use timeout to determine how long to wait for Gcr to provide a system prompt before giving up. (_gcr_timeout_done): New. Record that a timeout has elapsed. (gnome3_cmd_handler): Set up a timeout before launching the prompt, and tear it down afterward. (_gcr_prompt_password_done): Report timeout differently from normal cancellation. (_gcr_prompt_confirm_done): Report timeout differently from normal cancellation.
Without this change, pinentry-gnome3 does not respect the timeout
parameter at all, and can hang indefinitely in the event that the
system prompter is locked or the user is ignoring the session.
- Signed-off-by: Daniel Kahn Gillmor <dkg@fifthhorseman.net>