From 48a6adee3e63d335ac431ff6a67351988e574b79 Mon Sep 17 00:00:00 2001 From: Andrew Gregory Date: Sat, 24 Nov 2018 15:56:12 -0800 Subject: always allow explicit empty siglevel for sync dbs An empty siglevel does not do any signature verification which is exactly what we want when compiled without gpg support. This is already allowed in other parts of the codebase and required for the test suite to pass when compiled without gpg support. Fixes: FS#60880 Signed-off-by: Andrew Gregory Signed-off-by: Allan McRae (cherry picked from commit 61fe73804305a8bbb434cdc245944df5284f1964) --- lib/libalpm/be_sync.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/lib/libalpm/be_sync.c b/lib/libalpm/be_sync.c index 5009a7da..14b97149 100644 --- a/lib/libalpm/be_sync.c +++ b/lib/libalpm/be_sync.c @@ -787,7 +787,7 @@ alpm_db_t *_alpm_db_register_sync(alpm_handle_t *handle, const char *treename, _alpm_log(handle, ALPM_LOG_DEBUG, "registering sync database '%s'\n", treename); #ifndef HAVE_LIBGPGME - if(level != ALPM_SIG_USE_DEFAULT) { + if(level != 0 && level != ALPM_SIG_USE_DEFAULT) { RET_ERR(handle, ALPM_ERR_WRONG_ARGS, NULL); } #endif -- cgit v1.2.3-24-g4f1b