Introduce xbps_plist_{array,dictionary}_from_file().
Those are a wrapper around xbps_{array,dictionary}_internalize_from_zfile() that prints a debugging msg when the plist file cannot be internalized. Update xbps to use these wrappers.
This commit is contained in:
@@ -598,7 +598,7 @@ main(int argc, char **argv)
|
||||
if (conf_file == NULL)
|
||||
conf_file = _DGRAPH_CFFILE;
|
||||
|
||||
confd = xbps_dictionary_internalize_from_zfile(conf_file);
|
||||
confd = xbps_plist_dictionary_from_file(&xh, conf_file);
|
||||
if (confd == NULL) {
|
||||
if (errno != ENOENT)
|
||||
die("cannot read conf file `%s'", conf_file);
|
||||
|
@@ -95,7 +95,7 @@ check_pkg_integrity(struct xbps_handle *xhp,
|
||||
buf = xbps_xasprintf("%s/.%s-files.plist",
|
||||
xhp->metadir, pkgname);
|
||||
assert(buf);
|
||||
filesd = xbps_dictionary_internalize_from_zfile(buf);
|
||||
filesd = xbps_plist_dictionary_from_file(xhp, buf);
|
||||
if (filesd == NULL) {
|
||||
fprintf(stderr, "%s: cannot read %s, ignoring...\n",
|
||||
pkgname, buf);
|
||||
|
Reference in New Issue
Block a user