diff options
author | Aaron Griffin <aaron@archlinux.org> | 2007-02-26 08:38:48 +0000 |
---|---|---|
committer | Aaron Griffin <aaron@archlinux.org> | 2007-02-26 08:38:48 +0000 |
commit | 8fbdd03cce3c04a8208df30f435bc3e91a84ade3 (patch) | |
tree | c7ca34f17eff52f9e85d8f1b1bd3be2ecb292753 /lib/libalpm/alpm.c | |
parent | 52376150fa267f4f69af75cb9ff4a720430a5083 (diff) | |
download | pacman-8fbdd03cce3c04a8208df30f435bc3e91a84ade3.tar.xz |
* Enforce const char* params when using strings
* Unified some functions names "package" -> "pkg" for consistency
* Removed the goofy 'faketarget' stuff used for dep testing
* Renamed alpm_pkg_isin -> alpm_pkg_find
* Renamed alpm_db_readpkg -> alpm_db_get_pkg
Diffstat (limited to 'lib/libalpm/alpm.c')
-rw-r--r-- | lib/libalpm/alpm.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/lib/libalpm/alpm.c b/lib/libalpm/alpm.c index ba96606f..fe7a369f 100644 --- a/lib/libalpm/alpm.c +++ b/lib/libalpm/alpm.c @@ -330,7 +330,7 @@ int SYMEXPORT alpm_db_update(int force, pmdb_t *db) * @param name of the package * @return the package entry on success, NULL on error */ -pmpkg_t SYMEXPORT *alpm_db_readpkg(pmdb_t *db, char *name) +pmpkg_t SYMEXPORT *alpm_db_get_pkg(pmdb_t *db, const char *name) { ALPM_LOG_FUNC; @@ -362,7 +362,7 @@ alpm_list_t SYMEXPORT *alpm_db_getpkgcache(pmdb_t *db) * @param name name of the package * @return the list of packages on success, NULL on error */ -alpm_list_t SYMEXPORT *alpm_db_whatprovides(pmdb_t *db, char *name) +alpm_list_t SYMEXPORT *alpm_db_whatprovides(pmdb_t *db, const char *name) { ALPM_LOG_FUNC; @@ -379,7 +379,7 @@ alpm_list_t SYMEXPORT *alpm_db_whatprovides(pmdb_t *db, char *name) * @param name of the group * @return the groups entry on success, NULL on error */ -pmgrp_t SYMEXPORT *alpm_db_readgrp(pmdb_t *db, char *name) +pmgrp_t SYMEXPORT *alpm_db_readgrp(pmdb_t *db, const char *name) { ALPM_LOG_FUNC; @@ -1153,7 +1153,7 @@ alpm_list_t *alpm_get_upgrades() for(j = syncpkgs; j && !replace; j=j->next) { sync = j->data; if(sync->type == PM_SYNC_TYPE_REPLACE) { - if(_alpm_pkg_isin(spkg->name, sync->data)) { + if(_alpm_pkg_find(spkg->name, sync->data)) { replace=1; } } |