Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
tools: bpftool: maps: close json array on error paths of show
We can't return from the middle of do_show(), because json_array will not be closed. Break out of the loop. Note that the error handling after the loop depends on errno, so no need to set err. Fixes: 831a0aa ("tools: bpftool: add JSON output for `bpftool map *` commands") Signed-off-by: Jakub Kicinski <[email protected]> Acked-by: Quentin Monnet <[email protected]> Signed-off-by: Daniel Borkmann <[email protected]>
- Loading branch information