mirror of
git://git.gnupg.org/gnupg.git
synced 2025-01-03 12:11:33 +01:00
* gpgsm.c (main): New option --debug-wait n, so that it is
possible to attach gdb when used in server mode.
This commit is contained in:
parent
61ba223221
commit
b47b62b5f5
@ -1,5 +1,8 @@
|
||||
2001-12-14 Werner Koch <wk@gnupg.org>
|
||||
|
||||
* gpgsm.c (main): New option --debug-wait n, so that it is
|
||||
possible to attach gdb when used in server mode.
|
||||
|
||||
* sign.c (get_default_signer): Use keydb_classify_name here.
|
||||
|
||||
2001-12-14 Marcus Brinkmann <marcus@g10code.de>
|
||||
|
@ -187,14 +187,6 @@ start_agent (void)
|
||||
}
|
||||
|
||||
log_debug ("connection to agent established\n");
|
||||
|
||||
if (DBG_AGENT)
|
||||
{
|
||||
log_debug ("waiting for debugger [hit RETURN when ready] .....\n");
|
||||
getchar ();
|
||||
log_debug ("... okay\n");
|
||||
}
|
||||
|
||||
return 0;
|
||||
}
|
||||
|
||||
|
25
sm/gpgsm.c
25
sm/gpgsm.c
@ -76,9 +76,18 @@ enum cmd_and_opt_values {
|
||||
aCheckKeys,
|
||||
aServer,
|
||||
|
||||
oOptions,
|
||||
oDebug,
|
||||
oDebugAll,
|
||||
oDebugWait,
|
||||
|
||||
oEnableSpecialFilenames,
|
||||
oAgentProgram,
|
||||
|
||||
|
||||
|
||||
|
||||
|
||||
oAssumeArmor,
|
||||
oAssumeBase64,
|
||||
oAssumeBinary,
|
||||
@ -87,6 +96,7 @@ enum cmd_and_opt_values {
|
||||
oNoArmor,
|
||||
|
||||
|
||||
|
||||
oTextmode,
|
||||
oFingerprint,
|
||||
oWithFingerprint,
|
||||
@ -98,9 +108,6 @@ enum cmd_and_opt_values {
|
||||
oDefRecipient,
|
||||
oDefRecipientSelf,
|
||||
oNoDefRecipient,
|
||||
oOptions,
|
||||
oDebug,
|
||||
oDebugAll,
|
||||
oStatusFD,
|
||||
oNoComment,
|
||||
oNoVersion,
|
||||
@ -259,6 +266,7 @@ static ARGPARSE_OPTS opts[] = {
|
||||
|
||||
{ oDebug, "debug" ,4|16, "@"},
|
||||
{ oDebugAll, "debug-all" ,0, "@"},
|
||||
{ oDebugWait, "debug-wait" ,1, "@"},
|
||||
{ oStatusFD, "status-fd" ,1, N_("|FD|write status info to this FD") },
|
||||
{ aDummy, "no-comment", 0, "@"},
|
||||
{ aDummy, "completes-needed", 1, "@"},
|
||||
@ -537,6 +545,7 @@ main ( int argc, char **argv)
|
||||
int default_keyring = 1;
|
||||
int greeting = 0;
|
||||
int nogreeting = 0;
|
||||
int debug_wait = 0;
|
||||
int use_random_seed = 1;
|
||||
int with_fpr = 0;
|
||||
char *def_digest_string = NULL;
|
||||
@ -749,6 +758,7 @@ main ( int argc, char **argv)
|
||||
|
||||
case oDebug: opt.debug |= pargs.r.ret_ulong; break;
|
||||
case oDebugAll: opt.debug = ~0; break;
|
||||
case oDebugWait: debug_wait = pargs.r.ret_int; break;
|
||||
|
||||
case oStatusFD: ctrl.status_fd = pargs.r.ret_int; break;
|
||||
case oLoggerFD: /* fixme: log_set_logfile (NULL, pargs.r.ret_int );*/ break;
|
||||
@ -950,12 +960,13 @@ main ( int argc, char **argv)
|
||||
switch (cmd)
|
||||
{
|
||||
case aServer:
|
||||
#if 0
|
||||
log_debug ("waiting for debugger my pid is %u .....\n",
|
||||
if (debug_wait)
|
||||
{
|
||||
log_debug ("waiting for debugger - my pid is %u .....\n",
|
||||
(unsigned int)getpid());
|
||||
sleep (5);
|
||||
sleep (debug_wait);
|
||||
log_debug ("... okay\n");
|
||||
#endif
|
||||
}
|
||||
gpgsm_server ();
|
||||
break;
|
||||
|
||||
|
Loading…
x
Reference in New Issue
Block a user