Fix xbps_prepare_pkg() in pkgs without deps.
--HG-- extra : convert_revision : 9be76ef482e54bfbd7e6a038a504f8225aa89cfe
This commit is contained in:
parent
ad0bdbc375
commit
01be3b5920
|
@ -208,6 +208,20 @@ xbps_prepare_pkg(const char *pkgname)
|
|||
*/
|
||||
if ((rv = xbps_sort_pkg_deps(pkg_props)) != 0)
|
||||
goto out;
|
||||
} else {
|
||||
/*
|
||||
* Package has no deps, so we have to create the
|
||||
* "packages" array.
|
||||
*/
|
||||
pkgs_array = prop_array_create();
|
||||
if (pkgs_array == NULL) {
|
||||
rv = errno;
|
||||
goto out;
|
||||
}
|
||||
if (!prop_dictionary_set(pkg_props, "packages", pkgs_array)) {
|
||||
rv = errno;
|
||||
goto out;
|
||||
}
|
||||
}
|
||||
|
||||
/*
|
||||
|
|
Loading…
Reference in New Issue
Block a user