From: Michael Schroeder Date: Mon, 3 Jun 2019 14:08:13 +0000 (+0200) Subject: Fix warnings found by clang X-Git-Tag: 0.7.5~7 X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=eabce749f765b830dd5dc235020973bf19ceefe0;p=thirdparty%2Flibsolv.git Fix warnings found by clang --- diff --git a/src/selection.c b/src/selection.c index f8ca1f6a..e58d731a 100644 --- a/src/selection.c +++ b/src/selection.c @@ -1571,7 +1571,7 @@ selection_make_matchdeps_common(Pool *pool, Queue *selection, const char *name, revr = pool_str2id(pool, r, 1); ret |= SELECTION_REL; } - if ((flags & SELECTION_GLOB) != 0 && !strpbrk(rname, "[*?") != 0) + if ((flags & SELECTION_GLOB) != 0 && strpbrk(rname, "[*?") == 0) flags &= ~SELECTION_GLOB; if ((flags & SELECTION_GLOB) == 0 && (flags & SELECTION_NOCASE) == 0 && (flags & SELECTION_MATCH_DEPSTR) == 0) diff --git a/src/solvable.c b/src/solvable.c index 5bbc4b95..d3d2d31d 100644 --- a/src/solvable.c +++ b/src/solvable.c @@ -300,7 +300,7 @@ solvable_lookup_bool(Solvable *s, Id keyname) type = repo_lookup_type(s->repo, s - s->repo->pool->solvables, keyname); if (type == REPOKEY_TYPE_VOID) return 1; - if (type == REPOKEY_TYPE_NUM || REPOKEY_TYPE_CONSTANT) + if (type == REPOKEY_TYPE_NUM || type == REPOKEY_TYPE_CONSTANT) return repo_lookup_num(s->repo, s - s->repo->pool->solvables, keyname, 0) == 1; return 0; }