Clean up formatting in rpmdbCountPackages() (just cosmetics)

This commit is contained in:
Panu Matilainen 2010-04-01 16:58:12 +03:00
parent 76b36936ea
commit 91953f1f93
1 changed files with 3 additions and 7 deletions

View File

@ -1065,16 +1065,13 @@ int rpmdbCountPackages(rpmdb db, const char * name)
dbcursor = NULL;
if (rc == 0) { /* success */
dbiIndexSet matches;
/* FIX: matches might be NULL */
matches = NULL;
dbiIndexSet matches = NULL;
(void) dbt2set(dbi, &data, &matches);
if (matches) {
rc = dbiIndexSetCount(matches);
matches = dbiFreeIndexSet(matches);
}
} else
if (rc == DB_NOTFOUND) { /* not found */
} else if (rc == DB_NOTFOUND) { /* not found */
rc = 0;
} else { /* error */
rpmlog(RPMLOG_ERR,
@ -1119,8 +1116,7 @@ static rpmRC dbiFindMatches(rpmdb db, dbiIndex dbi, DBC * dbcursor,
(void) dbt2set(dbi, data, matches);
if (version == NULL && release == NULL)
return RPMRC_OK;
} else
if (rc == DB_NOTFOUND) { /* not found */
} else if (rc == DB_NOTFOUND) { /* not found */
return RPMRC_NOTFOUND;
} else { /* error */
rpmlog(RPMLOG_ERR,