summaryrefslogtreecommitdiffstats
path: root/lib/libalpm/alpm.c
diff options
context:
space:
mode:
authorAurelien Foret <aurelien@archlinux.org>2006-03-08 19:07:58 +0100
committerAurelien Foret <aurelien@archlinux.org>2006-03-08 19:07:58 +0100
commit4f42a0accb04936acb6eeb640e5bc09a556eac57 (patch)
treebaf6422b479604fa12da47e8243edfcbfdb691a1 /lib/libalpm/alpm.c
parent230d9d7ae3c3ebc64e922611567841b6fe692f3f (diff)
downloadpacman-4f42a0accb04936acb6eeb640e5bc09a556eac57.tar.gz
pacman-4f42a0accb04936acb6eeb640e5bc09a556eac57.tar.xz
all _alpm_XXX_cmp functions are now public
Diffstat (limited to 'lib/libalpm/alpm.c')
-rw-r--r--lib/libalpm/alpm.c14
1 files changed, 1 insertions, 13 deletions
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;
}