From 2c6fc088b90c0680b540aa39951fe9360b049d3b Mon Sep 17 00:00:00 2001 From: Packit Service Date: Dec 15 2020 18:49:53 +0000 Subject: Apply patch openscap-1.3.5-bump-yamlfilter-covscan-fix-PR_1620.patch patch_name: openscap-1.3.5-bump-yamlfilter-covscan-fix-PR_1620.patch present_in_specfile: true --- diff --git a/src/OVAL/probes/independent/yamlfilecontent_probe.c b/src/OVAL/probes/independent/yamlfilecontent_probe.c index 1e3c62f..205510d 100644 --- a/src/OVAL/probes/independent/yamlfilecontent_probe.c +++ b/src/OVAL/probes/independent/yamlfilecontent_probe.c @@ -215,12 +215,13 @@ static int yaml_path_query(const char *filepath, const char *yaml_path_cstr, str result_error("YAML parser error: %s", parser.problem); goto cleanup; } + + event_type = event.type; + if (yaml_path_filter_event(yaml_path, &parser, &event) == YAML_PATH_FILTER_RESULT_OUT) { goto next; } - event_type = event.type; - if (sequence) { if (event_type == YAML_SEQUENCE_END_EVENT) { sequence = false;