tools/bpftool: fix skeleton codegen
Subsystems (4)
PATCH 1/1 tools/bpftool: fix skeleton codegen
Remove unnecessary check at the end of codegen() routine which makes codegen() to always fail and exit bpftool with error code. Positive value of variable n is not an indicator of a failure.
Cc Tobias Klauser <[email protected]>
Fixes 2c4779eff837 ("tools, bpftool: Exit on error in function codegen")
Signed-off-by Andrii Nakryiko <[email protected]>
--- tools/bpf/bpftool/gen.c | 2 -- 1 file changed, 2 deletions(-)
tools/bpf/bpftool/gen.c +0 -2
@@ -257,8 +257,6 @@ static void codegen(const char *template, ...)va_end (args);free (s); -if (n) -exit (-1 ); }static int do_skeleton (int argc,char **argv)
Signature · 1 line
2.24.1
Quoted 7 lines · Andrii Nakryiko
Remove unnecessary check at the end of
codegen()routine which makescodegen()to always fail and exit bpftool with error code. Positive value of variable n is not an indicator of a failure.Cc Tobias Klauser <[email protected]>Fixes 2c4779eff837 ("tools, bpftool: Exit on error in function codegen")Signed-off-by Andrii Nakryiko <[email protected]>
Reviewed-by Tobias Klauser <[email protected]>
Sorry about this, thanks for fixing it.
Alexei Starovoitov
AppliedQuoted 6 lines · Tobias Klauser
Quoted 4 lines · Andrii Nakryiko
Remove unnecessary check at the end of
codegen()routine which makescodegen()to always fail and exit bpftool with error code. Positive value of variable n is not an indicator of a failure.
Quoted 7 lines
Quoted 3 lines
Cc Tobias Klauser <[email protected]>Fixes 2c4779eff837 ("tools, bpftool: Exit on error in function codegen")Signed-off-by Andrii Nakryiko <[email protected]>Reviewed-by Tobias Klauser <[email protected]>Sorry about this, thanks for fixing it.
Applied. Thanks