summaryrefslogtreecommitdiffstats
path: root/g10/import.c
diff options
context:
space:
mode:
authorWerner Koch <wk@gnupg.org>2019-07-09 11:13:51 +0200
committerWerner Koch <wk@gnupg.org>2019-07-09 11:13:51 +0200
commita29156d5a650702ad79fe11f45782bc4bc159c13 (patch)
tree0757227c3ecac173429fb0728e0a70f9ce1a05f5 /g10/import.c
parentgpg: Fix regression in option "self-sigs-only". (diff)
downloadgnupg2-a29156d5a650702ad79fe11f45782bc4bc159c13.tar.xz
gnupg2-a29156d5a650702ad79fe11f45782bc4bc159c13.zip
gpg: Do not try the import fallback if the options are already used.
* g10/import.c (import_one): Check options. Signed-off-by: Werner Koch <wk@gnupg.org>
Diffstat (limited to 'g10/import.c')
-rw-r--r--g10/import.c4
1 files changed, 3 insertions, 1 deletions
diff --git a/g10/import.c b/g10/import.c
index ceba15b68..32c0f65cb 100644
--- a/g10/import.c
+++ b/g10/import.c
@@ -2337,7 +2337,9 @@ import_one (ctrl_t ctrl,
from_sk, silent, screener, screener_arg,
origin, url, r_valid);
if (gpg_err_code (err) == GPG_ERR_TOO_LARGE
- && gpg_err_source (err) == GPG_ERR_SOURCE_KEYBOX)
+ && gpg_err_source (err) == GPG_ERR_SOURCE_KEYBOX
+ && ((options & (IMPORT_SELF_SIGS_ONLY | IMPORT_CLEAN))
+ != (IMPORT_SELF_SIGS_ONLY | IMPORT_CLEAN)))
{
/* We hit the maximum image length. Ask the wrapper to do
* everything again but this time with some extra options. */