Fixed a bug in rpool to find best pkg available.

This commit is contained in:
Juan RP 2012-01-29 12:12:00 +01:00
parent 1acf933f5a
commit f48ab4a686
2 changed files with 2 additions and 2 deletions

View File

@ -56,7 +56,7 @@
*/
#define XBPS_PKGINDEX_VERSION "1.4"
#define XBPS_API_VERSION "20120125-1"
#define XBPS_API_VERSION "20120129"
#define XBPS_VERSION "0.12"
/**

View File

@ -163,7 +163,7 @@ repo_find_best_pkg_cb(struct repository_pool_index *rpi,
* Compare current stored version against new
* version from current package in repository.
*/
if (xbps_cmpver(repopkgver, rpf->bestpkgver)) {
if (xbps_cmpver(repopkgver, rpf->bestpkgver) == 1) {
xbps_dbg_printf("[rpool] Found best match '%s' (%s).\n",
repopkgver, rpi->rpi_uri);
rpf->bestpkgver = repopkgver;