mirror of
git://git.gnupg.org/gnupg.git
synced 2025-01-21 14:47:03 +01:00
g10: Clean keyblock on initial commit.
* g10/import.c (import_one): If option import-clean is set, also clean on initial import, not only for merge. Signed-off-by: Marcus Brinkmann <mb@g10code.com> GnuPG-bug-id: 2401
This commit is contained in:
parent
d8a55da715
commit
609bbdf361
@ -1606,6 +1606,7 @@ import_one (ctrl_t ctrl,
|
||||
else if (rc ) /* Insert this key. */
|
||||
{
|
||||
KEYDB_HANDLE hd;
|
||||
int n_sigs_cleaned, n_uids_cleaned;
|
||||
|
||||
hd = keydb_new ();
|
||||
if (!hd)
|
||||
@ -1635,6 +1636,10 @@ import_one (ctrl_t ctrl,
|
||||
}
|
||||
}
|
||||
|
||||
if ((options & IMPORT_CLEAN))
|
||||
clean_key (ctrl, keyblock, opt.verbose, (options&IMPORT_MINIMAL),
|
||||
&n_uids_cleaned,&n_sigs_cleaned);
|
||||
|
||||
rc = keydb_insert_keyblock (hd, keyblock );
|
||||
if (rc)
|
||||
log_error (_("error writing keyring '%s': %s\n"),
|
||||
|
Loading…
x
Reference in New Issue
Block a user