rpmlog(RPMLOG_NOTICE,
_("group %s does not contain any packages\n"), arg);
res = 1;
- } else
- res = rpmcliShowMatches(qva, ts);
+ }
break;
case RPMQV_TRIGGEREDBY:
if (qva->qva_mi == NULL) {
rpmlog(RPMLOG_NOTICE, _("no package triggers %s\n"), arg);
res = 1;
- } else
- res = rpmcliShowMatches(qva, ts);
+ }
break;
case RPMQV_PKGID:
rpmlog(RPMLOG_NOTICE, _("no package matches %s: %s\n"),
"pkgid", arg);
res = 1;
- } else
- res = rpmcliShowMatches(qva, ts);
+ }
} break;
case RPMQV_HDRID:
rpmlog(RPMLOG_NOTICE, _("no package matches %s: %s\n"),
"hdrid", arg);
res = 1;
- } else
- res = rpmcliShowMatches(qva, ts);
+ }
break;
case RPMQV_FILEID:
rpmlog(RPMLOG_NOTICE, _("no package matches %s: %s\n"),
"fileid", arg);
res = 1;
- } else
- res = rpmcliShowMatches(qva, ts);
+ }
free(digest);
} break;
rpmlog(RPMLOG_NOTICE, _("no package matches %s: %s\n"),
"tid", arg);
res = 1;
- } else
- res = rpmcliShowMatches(qva, ts);
+ }
} break;
case RPMQV_WHATREQUIRES:
if (qva->qva_mi == NULL) {
rpmlog(RPMLOG_NOTICE, _("no package requires %s\n"), arg);
res = 1;
- } else
- res = rpmcliShowMatches(qva, ts);
+ }
break;
case RPMQV_WHATPROVIDES:
if (qva->qva_mi == NULL) {
rpmlog(RPMLOG_NOTICE, _("no package provides %s\n"), arg);
res = 1;
- } else
- res = rpmcliShowMatches(qva, ts);
+ }
break;
}
case RPMQV_PATH:
rpmlog(RPMLOG_NOTICE,
_("file %s is not owned by any package\n"), fn);
res = 1;
- } else
- res = rpmcliShowMatches(qva, ts);
+ }
fn = _free(fn);
} break;
rpmlog(RPMLOG_ERR,
_("record %u could not be read\n"), recOffset);
res = 1;
- } else
- res = rpmcliShowMatches(qva, ts);
+ }
} break;
case RPMQV_PACKAGE:
res = 1;
} else {
qva->qva_mi = rpmtsInitIterator(ts, RPMDBI_LABEL, arg, 0);
- res = rpmcliShowMatches(qva, ts);
}
break;
}
break;
}
- qva->qva_mi = rpmdbFreeIterator(qva->qva_mi);
+ if (qva->qva_source != RPMQV_SPECFILE && qva->qva_mi != NULL) {
+ res = rpmcliShowMatches(qva, ts);
+ qva->qva_mi = rpmdbFreeIterator(qva->qva_mi);
+ }
return res;
}