Fix warnings detected by LTO.
This commit is contained in:
parent
e7c1f411ec
commit
530e79c7ee
@ -428,7 +428,7 @@ create_dot_graph(struct xbps_handle *xhp,
|
||||
{
|
||||
xbps_dictionary_t sub_confd;
|
||||
xbps_array_t allkeys, rdeps;
|
||||
const char *pkgver, *cfprop;
|
||||
const char *pkgver = NULL, *cfprop;
|
||||
|
||||
xbps_dictionary_get_cstring_nocopy(plistd, "pkgver", &pkgver);
|
||||
|
||||
|
@ -539,14 +539,16 @@ pkgdb_get_pkgs_cb(struct xbps_handle *xhp UNUSED,
|
||||
void *arg, bool *done UNUSED)
|
||||
{
|
||||
xbps_array_t *array = arg;
|
||||
const char *pkgname;
|
||||
const char *pkgname = NULL;
|
||||
bool automatic = false;
|
||||
|
||||
xbps_dictionary_get_bool(obj, "automatic-install", &automatic);
|
||||
if (automatic)
|
||||
return 0;
|
||||
|
||||
xbps_dictionary_get_cstring_nocopy(obj, "pkgname", &pkgname);
|
||||
if (!xbps_dictionary_get_cstring_nocopy(obj, "pkgname", &pkgname))
|
||||
return EINVAL;
|
||||
|
||||
xbps_array_add_cstring_nocopy(*array, pkgname);
|
||||
return 0;
|
||||
}
|
||||
|
@ -494,7 +494,7 @@ remove_obsoletes(struct xbps_handle *xhp, const char *pkgname, const char *pkgve
|
||||
for (unsigned int i = 0; i < xbps_array_count(allkeys); i++) {
|
||||
xbps_array_t array, array2, array_repo;
|
||||
xbps_object_t keysym;
|
||||
const char *keyname, *first;
|
||||
const char *keyname, *first = NULL;
|
||||
|
||||
keysym = xbps_array_get(allkeys, i);
|
||||
array = xbps_dictionary_get_keysym(pkgd_alts, keysym);
|
||||
|
@ -114,7 +114,7 @@ xbps_find_pkg_orphans(struct xbps_handle *xhp, xbps_array_t orphans_user)
|
||||
}
|
||||
/* verify all revdeps are seen */
|
||||
for (unsigned int i = 0; i < revdepscnt; i++) {
|
||||
const char *revdepver;
|
||||
const char *revdepver = NULL;
|
||||
|
||||
xbps_array_get_cstring_nocopy(revdeps, i, &revdepver);
|
||||
if (xbps_find_pkg_in_array(array, revdepver, 0))
|
||||
|
@ -215,7 +215,7 @@ xbps_transaction_check_revdeps(struct xbps_handle *xhp, xbps_array_t pkgs)
|
||||
}
|
||||
|
||||
for (unsigned int j = 0; j < xbps_array_count(rundeps); j++) {
|
||||
const char *curdep;
|
||||
const char *curdep = NULL;
|
||||
|
||||
xbps_array_get_cstring_nocopy(rundeps, j, &curdep);
|
||||
if ((!xbps_pkgpattern_name(curdepname, sizeof(curdepname), curdep)) &&
|
||||
|
Loading…
Reference in New Issue
Block a user