[pacman-dev] [PATCH] Fix registering database with non-gpgme builds
We record whether the default SigLevel is set in order to add upon it for the *FileSigLevel entries. When using the only valid value of "SigLevel = Never" with non-gpgme builds, we need to ignore the ALPM_SIG_PACKAGE_SET flag when determining if we have a valid value for the database SigLevel. Signed-off-by: Allan McRae <allan@archlinux.org> --- 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 92be949..1cbe055 100644 --- a/lib/libalpm/be_sync.c +++ b/lib/libalpm/be_sync.c @@ -651,7 +651,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 != 0 && level != ALPM_SIG_USE_DEFAULT) { + if((level &= ~ALPM_SIG_PACKAGE_SET) != 0 && level != ALPM_SIG_USE_DEFAULT) { RET_ERR(handle, ALPM_ERR_WRONG_ARGS, NULL); } #endif -- 1.8.1.3
participants (1)
-
Allan McRae