-
Notifications
You must be signed in to change notification settings - Fork 2.5k
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 a potential segfault in podman search #2651
Fix a potential segfault in podman search #2651
Conversation
[APPROVALNOTIFIER] This PR is APPROVED This pull-request has been approved by: mheon The full list of commands accepted by this bot can be found here. The pull request process is described here
Needs approval from an approver in each of these files:
Approvers can indicate their approval by writing |
e4d3450
to
9f14ec5
Compare
bot, retest this please |
9f14ec5
to
60aed1f
Compare
☔ The latest upstream changes (presumably #2620) made this pull request unmergeable. Please resolve the merge conflicts. |
@mheon Needs a rebase. |
60aed1f
to
e944def
Compare
Rebased, should be good to merge now |
/lgtm |
/retest |
@mheon This might need a new rebase? |
e944def
to
328b2ac
Compare
Rebased again |
Seems to be failing on search. |
When generating headers for search, we unconditionally access element 0 of an array, and I saw this segfault in our CI. There's no reason we have to do this, we're just going through it to get field names with reflect, so just make a new copy of the struct in question. Also, move this code, which is only for CLI display, into cmd/podman from libpod/image. Signed-off-by: Matthew Heon <mheon@redhat.com>
328b2ac
to
c625553
Compare
Alright, let's see... This ought to fix it |
Yep, tests good |
/lgtm |
When generating headers for search, we unconditionally access element 0 of an array, and I saw this segfault in our CI. There's no reason we have to do this, we're just going through it to get field names with reflect, so just make a new copy of the struct in question.
Also, move this code, which is only for CLI display, into cmd/podman from libpod/image.