diff mbox series

[iproute2,2/2] tc: print unknown action on stderr

Message ID 20240209235612.404888-2-stephen@networkplumber.org (mailing list archive)
State Accepted
Commit b958d3c25dccdf83c2499ab7f6d6931e878efa46
Delegated to: David Ahern
Headers show
Series [iproute2,1/2] tc: bpf: fix extra newline in JSON output | expand

Checks

Context Check Description
netdev/tree_selection success Not a local patch

Commit Message

Stephen Hemminger Feb. 9, 2024, 11:55 p.m. UTC
This is an error, and should not go to stdout.

Signed-off-by: Stephen Hemminger <stephen@networkplumber.org>
---
 tc/m_action.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)
diff mbox series

Patch

diff --git a/tc/m_action.c b/tc/m_action.c
index 16474c56118c..f180ba09778c 100644
--- a/tc/m_action.c
+++ b/tc/m_action.c
@@ -62,7 +62,7 @@  static void act_usage(void)
 static int print_noaopt(struct action_util *au, FILE *f, struct rtattr *opt)
 {
 	if (opt && RTA_PAYLOAD(opt))
-		fprintf(f, "[Unknown action, optlen=%u] ",
+		fprintf(stderr, "[Unknown action, optlen=%u] ",
 			(unsigned int) RTA_PAYLOAD(opt));
 	return 0;
 }