Send patches - preferably formatted by git format-patch - to patches at archlinux32 dot org.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--lib/libalpm/be_sync.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/lib/libalpm/be_sync.c b/lib/libalpm/be_sync.c
index 5477eff4..4864616b 100644
--- a/lib/libalpm/be_sync.c
+++ b/lib/libalpm/be_sync.c
@@ -75,6 +75,7 @@ static int sync_db_validate(alpm_db_t *db)
return 0;
}
if(db->status & DB_STATUS_INVALID) {
+ db->handle->pm_errno = ALPM_ERR_DB_INVALID_SIG;
return -1;
}
@@ -117,6 +118,8 @@ static int sync_db_validate(alpm_db_t *db)
} while(retry);
if(ret) {
+ db->status &= ~DB_STATUS_VALID;
+ db->status |= DB_STATUS_INVALID;
db->handle->pm_errno = ALPM_ERR_DB_INVALID_SIG;
return 1;
}