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

Add iterator for bpf programs/maps in a bpf object #166

Merged
merged 4 commits into from May 6, 2022

Conversation

grantseltzer
Copy link
Contributor

Plus a helper for getting section name, and a selftest

Signed-off-by: grantseltzer <grantseltzer@gmail.com>
selftest

Signed-off-by: grantseltzer <grantseltzer@gmail.com>
Signed-off-by: grantseltzer <grantseltzer@gmail.com>
@grantseltzer grantseltzer changed the title Add iterator for bpf programs in a bpf object Add iterator for bpf programs/maps in a bpf object May 5, 2022
@rafaeldtinoco
Copy link
Contributor

Reviewing this one...

rafaeldtinoco
rafaeldtinoco previously approved these changes May 6, 2022
Copy link
Contributor

@rafaeldtinoco rafaeldtinoco left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM. There are 2 minor fixes over Println needed. Other than that, I think its good! Thanks.

}
for k, v := range expectedProgramNames {
if v == false {
fmt.Fprintln(os.Stderr, "did not iterate over expected program: %s", k)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fmt.Printf instead (you're using %s)

}
for k, v := range expectedMapNames {
if v == false {
fmt.Fprintln(os.Stderr, "did not iterate over expected map: %s", k)
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

fmt.Printf instead (you're using %s)

Signed-off-by: grantseltzer <grantseltzer@gmail.com>
@grantseltzer grantseltzer merged commit be71c35 into aquasecurity:main May 6, 2022
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants