Changeset View
Changeset View
Standalone View
Standalone View
dirmngr/server.c
Show First 20 Lines • Show All 2,683 Lines • ▼ Show 20 Lines | cmd_reloaddirmngr (assuan_context_t ctx, char *line) | ||||
(void)ctx; | (void)ctx; | ||||
(void)line; | (void)line; | ||||
dirmngr_sighup_action (); | dirmngr_sighup_action (); | ||||
return 0; | return 0; | ||||
} | } | ||||
static const char hlp_flushcrls[] = | |||||
"FLUSHCRLS\n" | |||||
"\n" | |||||
"Remove all cached CRLs from memory and\n" | |||||
"the file system."; | |||||
static gpg_error_t | |||||
cmd_flushcrls (assuan_context_t ctx, char *line) | |||||
{ | |||||
(void)line; | |||||
return leave_cmd (ctx, crl_cache_flush () ? GPG_ERR_GENERAL : 0); | |||||
werner: Please replace the last line with
return leave_cmd (ctx, crl_flush_cache ()? | |||||
} | |||||
␌ | ␌ | ||||
/* Tell the assuan library about our commands. */ | /* Tell the assuan library about our commands. */ | ||||
static int | static int | ||||
register_commands (assuan_context_t ctx) | register_commands (assuan_context_t ctx) | ||||
{ | { | ||||
static struct { | static struct { | ||||
const char *name; | const char *name; | ||||
assuan_handler_t handler; | assuan_handler_t handler; | ||||
Show All 14 Lines | static struct { | ||||
{ "KS_SEARCH", cmd_ks_search, hlp_ks_search }, | { "KS_SEARCH", cmd_ks_search, hlp_ks_search }, | ||||
{ "KS_GET", cmd_ks_get, hlp_ks_get }, | { "KS_GET", cmd_ks_get, hlp_ks_get }, | ||||
{ "KS_FETCH", cmd_ks_fetch, hlp_ks_fetch }, | { "KS_FETCH", cmd_ks_fetch, hlp_ks_fetch }, | ||||
{ "KS_PUT", cmd_ks_put, hlp_ks_put }, | { "KS_PUT", cmd_ks_put, hlp_ks_put }, | ||||
{ "GETINFO", cmd_getinfo, hlp_getinfo }, | { "GETINFO", cmd_getinfo, hlp_getinfo }, | ||||
{ "LOADSWDB", cmd_loadswdb, hlp_loadswdb }, | { "LOADSWDB", cmd_loadswdb, hlp_loadswdb }, | ||||
{ "KILLDIRMNGR",cmd_killdirmngr,hlp_killdirmngr }, | { "KILLDIRMNGR",cmd_killdirmngr,hlp_killdirmngr }, | ||||
{ "RELOADDIRMNGR",cmd_reloaddirmngr,hlp_reloaddirmngr }, | { "RELOADDIRMNGR",cmd_reloaddirmngr,hlp_reloaddirmngr }, | ||||
{ "FLUSHCRLS", cmd_flushcrls, hlp_flushcrls }, | |||||
{ NULL, NULL } | { NULL, NULL } | ||||
}; | }; | ||||
int i, j, rc; | int i, j, rc; | ||||
for (i=j=0; table[i].name; i++) | for (i=j=0; table[i].name; i++) | ||||
{ | { | ||||
rc = assuan_register_command (ctx, table[i].name, table[i].handler, | rc = assuan_register_command (ctx, table[i].name, table[i].handler, | ||||
table[i].help); | table[i].help); | ||||
▲ Show 20 Lines • Show All 311 Lines • Show Last 20 Lines |
Please replace the last line with