From 3ebd125e1ad9abbf5fbcb4457adb8288750b379e Mon Sep 17 00:00:00 2001 From: Aaron Griffin Date: Thu, 1 Mar 2007 07:03:05 +0000 Subject: * Switched some functions to alpm_pkg_get_* usage as I came across them * Added some provision switching hackery. This could probably use some refactoring,.. it solves the following case: pkg1 and pkg2 provide 'foo' and are both installed pkg3 depends on 'foo' and so lists 'pkg1' in the REQUIREDBY db section pkg1 is upgraded and no longer provides 'foo' ** This code ensures that the REQUIREDBY of pkg3 is updated to require pkg2 now instead of pkg1 --- lib/libalpm/versioncmp.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'lib/libalpm/versioncmp.c') diff --git a/lib/libalpm/versioncmp.c b/lib/libalpm/versioncmp.c index d23f0568..3356e99f 100644 --- a/lib/libalpm/versioncmp.c +++ b/lib/libalpm/versioncmp.c @@ -252,7 +252,7 @@ int _alpm_depcmp(pmpkg_t *pkg, pmdepend_t *dep) ALPM_LOG_FUNC; if(strcmp(pkg->name, dep->name) == 0 - || alpm_list_find_str(pkg->provides, dep->name)) { + || alpm_list_find_str(alpm_pkg_get_provides(pkg), dep->name)) { if(dep->mod == PM_DEP_MOD_ANY) { equal = 1; } else { -- cgit v1.2.3-70-g09d2