lib/package_configure.c: fix use-after-free reported by clang.
This commit is contained in:
parent
5c3c192d16
commit
4bc6ba2b1c
@ -96,9 +96,9 @@ xbps_configure_pkg(struct xbps_handle *xhp,
|
||||
}
|
||||
pkgd = xbps_pkgdb_get_pkg(xhp, pkgname);
|
||||
if (pkgd == NULL) {
|
||||
free(pkgname);
|
||||
xbps_dbg_printf(xhp, "[configure] cannot find %s (%s) "
|
||||
"in pkgdb\n", pkgname, pkgver);
|
||||
free(pkgname);
|
||||
return ENOENT;
|
||||
}
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user