* "ip help" output is an error
@ 2026-06-20 9:36 Dmitri Seletski
0 siblings, 0 replies; only message in thread
From: Dmitri Seletski @ 2026-06-20 9:36 UTC (permalink / raw)
To: netdev
Hello iproute2 maintainers,
I am reporting an inconsistency regarding the exit status of the ip help
command.
Current Behavior:
When running ip help, the command prints the help documentation to
stdout, but exits with a non-zero status (error). This causes issues in
shell scripts that rely on exit codes for control flow.
Steps to reproduce:
bash
# This returns "FAIL" because the exit code is non-zero
if ip help > /dev/null; then
echo "SUCCESS"
else
echo "FAIL"
fi
Expected Behavior:
Since the command successfully performs the requested task (displaying
help information) and does not encounter a system error, it should
return an exit code of 0.
Context:
This behavior breaks standard Bash logic for automation. For example:
ip help && echo "This will not execute"
"ip help |grep br" - this will bring no result.
Current version tested: iproute2-6.19.0
Thank you for your time and for maintaining this tool.
Regards,
Dmitri Seletski
^ permalink raw reply [flat|nested] only message in thread
only message in thread, other threads:[~2026-06-20 9:36 UTC | newest]
Thread overview: (only message) (download: mbox.gz follow: Atom feed
-- links below jump to the message on this page --
2026-06-20 9:36 "ip help" output is an error Dmitri Seletski
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox