Skip to content

Commit 7627132

Browse files
authored
Merge pull request #1384 from jan-cerny/rpminfo_no_filepaths
Fix missing filepaths in rpminfo items
2 parents e121009 + 61d2a73 commit 7627132

File tree

1 file changed

+2
-1
lines changed

1 file changed

+2
-1
lines changed

src/OVAL/probes/unix/linux/rpminfo.c

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -339,7 +339,8 @@ static int collect_rpm_files(SEXP_t *item, const struct rpminfo_rep *rep) {
339339
ret = -1;
340340
goto cleanup;
341341
}
342-
if (rpmdbSetIteratorRE(ts, RPMTAG_EPOCH, RPMMIRE_STRCMP, rep->epoch) != 0) {
342+
char *epoch_override = oscap_streq(rep->epoch, "(none)") ? "0" : rep->epoch;
343+
if (rpmdbSetIteratorRE(ts, RPMTAG_EPOCH, RPMMIRE_STRCMP, epoch_override) != 0) {
343344
ret = -1;
344345
goto cleanup;
345346
}

0 commit comments

Comments
 (0)