From 4f42a0accb04936acb6eeb640e5bc09a556eac57 Mon Sep 17 00:00:00 2001 From: Aurelien Foret Date: Wed, 8 Mar 2006 18:07:58 +0000 Subject: all _alpm_XXX_cmp functions are now public --- lib/libalpm/alpm.c | 14 +------------- 1 file changed, 1 insertion(+), 13 deletions(-) (limited to 'lib/libalpm/alpm.c') diff --git a/lib/libalpm/alpm.c b/lib/libalpm/alpm.c index 55c4e274..18021fba 100644 --- a/lib/libalpm/alpm.c +++ b/lib/libalpm/alpm.c @@ -217,18 +217,6 @@ pmdb_t *alpm_db_register(char *treename) return(db); } -/** Helper function for comparing databases - * @param db1 first database - * @param db2 second database - * @return an integer less than, equal to, or greater than zero if the name of - * db1 is found, respectively, to be less than, to match, or be greater than - * the name of db2. - */ -static int db_cmp(const void *db1, const void *db2) -{ - return(strcmp(((pmdb_t *)db1)->treename, ((pmdb_t *)db2)->treename)); -} - /** Unregister a package database * @param db pointer to the package database to unregister * @return 0 on success, -1 on error (pm_errno is set accordingly) @@ -248,7 +236,7 @@ int alpm_db_unregister(pmdb_t *db) found = 1; } else { pmdb_t *data; - handle->dbs_sync = _alpm_list_remove(handle->dbs_sync, db, db_cmp, (void **)&data); + handle->dbs_sync = _alpm_list_remove(handle->dbs_sync, db, _alpm_db_cmp, (void **)&data); if(data) { found = 1; } -- cgit v1.2.3-70-g09d2