Fixed issue 21 "xbps-repo find-files is awfully slow" reported by ojab.

This commit is contained in:
Juan RP
2012-01-15 14:24:44 +01:00
parent 8780e15635
commit 2186e16a5e
10 changed files with 322 additions and 90 deletions

View File

@@ -196,9 +196,20 @@ xbps_repository_pool_sync(const struct xbps_handle *xhp)
continue;
}
/*
* Fetch repository index file.
* Fetch repository index.plist.
*/
rv = xbps_repository_sync_pkg_index(repouri);
rv = xbps_repository_sync_pkg_index(repouri, XBPS_PKGINDEX);
if (rv == -1) {
xbps_dbg_printf("[rpool] `%s' failed to fetch: %s\n",
repouri, fetchLastErrCode == 0 ?
strerror(errno) : xbps_fetch_error_string());
continue;
}
/*
* Fetch repository index-files.plist.
*/
rv = xbps_repository_sync_pkg_index(repouri,
XBPS_PKGINDEX_FILES);
if (rv == -1) {
xbps_dbg_printf("[rpool] `%s' failed to fetch: %s\n",
repouri, fetchLastErrCode == 0 ?