diff options
author | Werner Koch <[email protected]> | 2016-01-20 10:22:44 +0000 |
---|---|---|
committer | Werner Koch <[email protected]> | 2016-01-20 10:22:44 +0000 |
commit | 499743387f4d07847a2842358bc54f9237e0c2a7 (patch) | |
tree | 3d10ca58841ea18472ad0a407cb6d216f8ec7e63 /agent/call-pinentry.c | |
parent | doc: Typo fix. (diff) | |
download | gnupg-499743387f4d07847a2842358bc54f9237e0c2a7.tar.gz gnupg-499743387f4d07847a2842358bc54f9237e0c2a7.zip |
agent: New option --pinentry-timeout
* agent/gpg-agent.c (oPinentryTimeout): New.
(opts): Add new option.
(parse_rereadable_options): PArse that option.
(main): Tell gpgconf about this option.
* agent/call-pinentry.c (start_pinentry): Send option to Pinentry.
* tools/gpgconf-comp.c (gc_options_gpg_agent): Add Option.
--
GnuPG-bug-id: 2222
Signed-off-by: Werner Koch <[email protected]>
Diffstat (limited to 'agent/call-pinentry.c')
-rw-r--r-- | agent/call-pinentry.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/agent/call-pinentry.c b/agent/call-pinentry.c index 33e3ec3c6..0f240866e 100644 --- a/agent/call-pinentry.c +++ b/agent/call-pinentry.c @@ -491,6 +491,18 @@ start_pinentry (ctrl_t ctrl) } } + if (opt.pinentry_timeout) + { + char *optstr; + if ((optstr = xtryasprintf ("SETTIMEOUT %lu", opt.pinentry_timeout))) + { + assuan_transact (entry_ctx, optstr, NULL, NULL, NULL, NULL, NULL, + NULL); + /* We ignore errors because this is just a fancy thing. */ + xfree (optstr); + } + } + /* Tell the pinentry the name of a file it shall touch after having messed with the tty. This is optional and only supported by newer pinentries and thus we do no error checking. */ |