Implemented a cache to get pkg dicts from metadir.
This improves xbps-pkgdb -a marginally, but still seems to be a bit slow.
This commit is contained in:
@ -44,13 +44,12 @@ show_pkg_deps(struct xbps_handle *xhp, const char *pkgname)
|
||||
/*
|
||||
* Check for props.plist metadata file.
|
||||
*/
|
||||
propsd = xbps_pkgd_from_metadir(xhp, pkgname);
|
||||
propsd = xbps_metadir_get_pkgd(xhp, pkgname);
|
||||
if (propsd == NULL)
|
||||
return ENOENT;
|
||||
|
||||
rv = xbps_callback_array_iter_in_dict(xhp, propsd, "run_depends",
|
||||
list_strings_sep_in_array, NULL);
|
||||
prop_object_release(propsd);
|
||||
|
||||
return rv;
|
||||
}
|
||||
|
Reference in New Issue
Block a user