xbps_rpool_sync: also fetch repository files index, removed accidently in previous.

This commit is contained in:
Juan RP 2012-06-01 15:45:49 +02:00
parent 0c52f3cce6
commit 642e6fca3a
2 changed files with 13 additions and 2 deletions

View File

@ -56,7 +56,7 @@
*/
#define XBPS_PKGINDEX_VERSION "1.5"
#define XBPS_API_VERSION "20120601-1"
#define XBPS_API_VERSION "20120601-2"
#define XBPS_VERSION "0.16"
/**

View File

@ -160,7 +160,7 @@ xbps_rpool_sync(const char *uri)
if (uri && strcmp(repouri, uri))
continue;
/*
* Fetch repository plist index.
* Fetch repository index.
*/
if (xbps_repository_sync_pkg_index(repouri, XBPS_PKGINDEX) == -1) {
rv = fetchLastErrCode != 0 ? fetchLastErrCode : errno;
@ -169,6 +169,17 @@ xbps_rpool_sync(const char *uri)
xbps_fetch_error_string());
continue;
}
/*
* Fetch repository files index.
*/
if (xbps_repository_sync_pkg_index(repouri,
XBPS_PKGINDEX_FILES) == -1) {
rv = fetchLastErrCode != 0 ? fetchLastErrCode : errno;
xbps_dbg_printf("[rpool] `%s' failed to fetch: %s\n",
repouri, fetchLastErrCode == 0 ? strerror(errno) :
xbps_fetch_error_string());
continue;
}
}
return rv;
}