summaryrefslogtreecommitdiffstats
path: root/tools
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2010-10-14 18:34:31 +0200
committerWerner Koch <wk@gnupg.org>2010-10-14 18:34:31 +0200
commit764e88d4df29204be6ea2206cf753c56ec0f5b5f (patch)
treed38aa151706b32ce1ddbec2e7f012d317618072a /tools
parentSome tweaks to the agent startup. (diff)
downloadgnupg2-764e88d4df29204be6ea2206cf753c56ec0f5b5f.tar.xz
gnupg2-764e88d4df29204be6ea2206cf753c56ec0f5b5f.zip
All tests work are again working
Diffstat (limited to 'tools')
-rw-r--r--tools/ChangeLog2
-rw-r--r--tools/gpg-connect-agent.c6
2 files changed, 7 insertions, 1 deletions
diff --git a/tools/ChangeLog b/tools/ChangeLog
index de148ba56..84fbe4098 100644
--- a/tools/ChangeLog
+++ b/tools/ChangeLog
@@ -1,5 +1,7 @@
2010-10-14 Werner Koch <wk@g10code.com>
+ * gpg-connect-agent.c: Add option --agent-program.
+
* gpg-connect-agent.c (start_agent): Rewrite using the
start_new_gpg_agent function.
diff --git a/tools/gpg-connect-agent.c b/tools/gpg-connect-agent.c
index 652f288c5..8de67bbf0 100644
--- a/tools/gpg-connect-agent.c
+++ b/tools/gpg-connect-agent.c
@@ -56,6 +56,7 @@ enum cmd_and_opt_values
oNoVerbose = 500,
oHomedir,
+ oAgentProgram,
oHex,
oDecode,
oNoExtConnect
@@ -85,6 +86,7 @@ static ARGPARSE_OPTS opts[] = {
ARGPARSE_s_n (oNoVerbose, "no-verbose", "@"),
ARGPARSE_s_s (oHomedir, "homedir", "@" ),
+ ARGPARSE_s_s (oAgentProgram, "agent-program", "@"),
ARGPARSE_end ()
};
@@ -96,6 +98,7 @@ struct
int verbose; /* Verbosity level. */
int quiet; /* Be extra quiet. */
const char *homedir; /* Configuration directory name */
+ const char *agent_program; /* Value of --agent-program. */
int hex; /* Print data lines in hex format. */
int decode; /* Decode received data lines. */
const char *raw_socket; /* Name of socket to connect in raw mode. */
@@ -1186,6 +1189,7 @@ main (int argc, char **argv)
case oVerbose: opt.verbose++; break;
case oNoVerbose: opt.verbose = 0; break;
case oHomedir: opt.homedir = pargs.r.ret_str; break;
+ case oAgentProgram: opt.agent_program = pargs.r.ret_str; break;
case oHex: opt.hex = 1; break;
case oDecode: opt.decode = 1; break;
case oRawSocket: opt.raw_socket = pargs.r.ret_str; break;
@@ -2168,7 +2172,7 @@ start_agent (void)
err = start_new_gpg_agent (&ctx,
GPG_ERR_SOURCE_DEFAULT,
opt.homedir,
- NULL,
+ opt.agent_program,
NULL, NULL,
session_env,
!opt.quiet, 0,