lists.openwall.net   lists  /  announce  owl-users  owl-dev  john-users  john-dev  passwdqc-users  yescrypt  popa3d-users  /  oss-security  kernel-hardening  musl  sabotage  tlsify  passwords  /  crypt-dev  xvendor  /  Bugtraq  Full-Disclosure  linux-kernel  linux-netdev  linux-ext4  linux-hardening  linux-cve-announce  PHC 
Open Source and information security mailing list archives
 
Hash Suite: Windows password security audit tool. GUI, reports in PDF.
[<prev] [next>] [thread-next>] [day] [month] [year] [list]
Message-Id: <1509053408-18007-1-git-send-email-mrv@mojatatu.com>
Date:   Thu, 26 Oct 2017 17:30:08 -0400
From:   Roman Mashak <mrv@...atatu.com>
To:     stephen@...workplumber.org
Cc:     jhs@...atatu.com, netdev@...r.kernel.org,
        Roman Mashak <mrv@...atatu.com>
Subject: [PATCH iproute2 1/1] tc: distinguish Add/Replace qdisc operations

Signed-off-by: Roman Mashak <mrv@...atatu.com>
---
 tc/tc_qdisc.c | 10 ++++++++++
 1 file changed, 10 insertions(+)

diff --git a/tc/tc_qdisc.c b/tc/tc_qdisc.c
index 1e9d909..493538c 100644
--- a/tc/tc_qdisc.c
+++ b/tc/tc_qdisc.c
@@ -231,6 +231,16 @@ int print_qdisc(const struct sockaddr_nl *who,
 	if (n->nlmsg_type == RTM_DELQDISC)
 		fprintf(fp, "deleted ");
 
+	if (n->nlmsg_type == RTM_NEWQDISC &&
+			(n->nlmsg_flags & NLM_F_CREATE) &&
+			(n->nlmsg_flags & NLM_F_REPLACE))
+		fprintf(fp, "replaced ");
+
+	if (n->nlmsg_type == RTM_NEWQDISC &&
+			(n->nlmsg_flags & NLM_F_CREATE) &&
+			(n->nlmsg_flags & NLM_F_EXCL))
+		fprintf(fp, "added ");
+
 	if (show_raw)
 		fprintf(fp, "qdisc %s %x:[%08x]  ",
 			rta_getattr_str(tb[TCA_KIND]),
-- 
1.9.1

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ