Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Fix export of overrided oscap_text #527

Merged
merged 2 commits into from Sep 16, 2016

Conversation

yuumasato
Copy link
Member

This change allows attributes marked as overriders by
oscap_text_set_override() to be exported.

Exportation of an overrider attribute is conditioned by override_given.
But override_given is only set when an imported attribute has override
capability set. So, when an oscap_text was marked as overrider by
oscap_text_set_set_override() the attribute was never exported.

Related to RHBZ#1320194.

This change allows attributes marked as overriders by
oscap_text_set_override() to be exported.

Exportation of an overrider attribute is conditioned by override_given.
But override_given is only set when an imported attribute has override
capability set. So, when an oscap_text was marked as overrider by
oscap_text_set_set_override() the attribute was never exported.

Related to RHBZ#1320194.
@mpreisler
Copy link
Member

Makes sense to me. The worst that can happen here is that we export the attribute when not necessary and that is not a major problem.

ACK but will wait for Jenkins.

@mpreisler mpreisler added this to the 1.0.11 milestone Sep 15, 2016
@mpreisler
Copy link
Member

I think the test file in parser unit test needs to be changed, override=false needs to be added so that the exported is exactly the same as imported. Then it should pass.

Export override attribute of oscap_text only when the element can
override parent value and it does override the value.

The default value for override is false, there is no need to export it
if it`s false.
@yuumasato
Copy link
Member Author

yuumasato commented Sep 16, 2016

Restricted the export of override attribute to true values only. There is no need to export override="false".

@mpreisler mpreisler self-assigned this Sep 16, 2016
@mpreisler
Copy link
Member

OK, ACK.

@mpreisler mpreisler merged commit a074b7a into OpenSCAP:maint-1.0 Sep 16, 2016
@yuumasato yuumasato deleted the maint-1.0-fix-export-override branch October 17, 2016 09:17
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants