2004-05-21 Marcus Brinkmann <marcus@g10code.de>

* gpgconf-comp.c (gc_component_change_options): Move the
	per-process backup file into a standard location.
This commit is contained in:
Marcus Brinkmann 2004-05-21 13:46:13 +00:00
parent 2cce42c23f
commit fb84c86f64
2 changed files with 17 additions and 0 deletions

View File

@ -1,3 +1,8 @@
2004-05-21 Marcus Brinkmann <marcus@g10code.de>
* gpgconf-comp.c (gc_component_change_options): Move the
per-process backup file into a standard location.
2004-05-03 Werner Koch <wk@gnupg.org>
* gpgconf-comp.c: Add --allow-mark-trusted for the gpg-agent.

View File

@ -2431,6 +2431,18 @@ gc_component_change_options (int component, FILE *in)
(*gc_backend[backend].runtime_change) ();
}
/* Move the per-process backup file into its place. */
for (backend = 0; backend < GC_BACKEND_NR; backend++)
if (orig_pathname[backend])
{
char *backup_pathname;
assert (dest_pathname[backend]);
backup_pathname = xasprintf ("%s.gpgconf.bak", dest_pathname[backend]);
rename (orig_pathname[backend], backup_pathname);
}
if (line)
free (line);
}