Re-use pkgname from unpack to handle config files.
This commit is contained in:
parent
faacbd4a96
commit
c504a73f08
@ -147,6 +147,7 @@ int HIDDEN xbps_entry_install_conf_file(struct xbps_handle *,
|
||||
prop_dictionary_t,
|
||||
struct archive_entry *,
|
||||
const char *,
|
||||
const char *,
|
||||
const char *);
|
||||
/**
|
||||
* @private
|
||||
|
@ -64,7 +64,8 @@ xbps_entry_install_conf_file(struct xbps_handle *xhp,
|
||||
prop_dictionary_t filesd,
|
||||
struct archive_entry *entry,
|
||||
const char *entry_pname,
|
||||
const char *pkgver)
|
||||
const char *pkgver,
|
||||
const char *pkgname)
|
||||
{
|
||||
prop_dictionary_t forigd;
|
||||
prop_object_t obj, obj2;
|
||||
@ -89,7 +90,7 @@ xbps_entry_install_conf_file(struct xbps_handle *xhp,
|
||||
xbps_dbg_printf(xhp, "%s: processing conf_file %s\n",
|
||||
pkgver, entry_pname);
|
||||
|
||||
forigd = xbps_pkgdb_get_pkg_metadata(xhp, pkgver);
|
||||
forigd = xbps_pkgdb_get_pkg_metadata(xhp, pkgname);
|
||||
if (forigd == NULL) {
|
||||
xbps_dbg_printf(xhp, "%s: conf_file %s not currently "
|
||||
"installed\n", pkgver, entry_pname);
|
||||
|
@ -310,7 +310,8 @@ unpack_archive(struct xbps_handle *xhp,
|
||||
xucd.entry_is_conf = true;
|
||||
|
||||
rv = xbps_entry_install_conf_file(xhp,
|
||||
filesd, entry, entry_pname, pkgver);
|
||||
filesd, entry, entry_pname, pkgver,
|
||||
pkgname);
|
||||
if (rv == -1) {
|
||||
/* error */
|
||||
goto out;
|
||||
|
Loading…
Reference in New Issue
Block a user