From e68e994eb2c32c4b7ad5288f8f4b8809e1c39c9b Mon Sep 17 00:00:00 2001 From: Dave Reisner Date: Thu, 24 Mar 2011 15:10:01 -0400 Subject: alpm/db: do not close local DB in alpm_db_unregister_all pacman 3.5.0 removed alpm_db_register_local, so calling alpm_db_unregister_all leaves the front end in a position where there's no local db, and no way to re-register it. Signed-off-by: Dave Reisner Signed-off-by: Dan McGee --- lib/libalpm/db.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) (limited to 'lib/libalpm/db.c') diff --git a/lib/libalpm/db.c b/lib/libalpm/db.c index fb64faed..bf6df06e 100644 --- a/lib/libalpm/db.c +++ b/lib/libalpm/db.c @@ -90,12 +90,8 @@ int SYMEXPORT alpm_db_unregister_all(void) /* Do not unregister a database if a transaction is on-going */ ASSERT(handle->trans == NULL, RET_ERR(PM_ERR_TRANS_NOT_NULL, -1)); - /* close local database */ - db = handle->db_local; - if(db) { - db->ops->unregister(db); - handle->db_local = NULL; - } + /* since the local DB is registered in alpm_initialize(), we'll be + * symmetrical and let the cleanup occur in alpm_release() */ /* and also sync ones */ for(i = handle->dbs_sync; i; i = i->next) { -- cgit v1.2.3-24-g4f1b