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-prev] [day] [month] [year] [list]
Date:   Mon, 7 Nov 2016 16:13:30 +0300
From:   Sergei Shtylyov <sergei.shtylyov@...entembedded.com>
To:     Roman Mashak <mrv@...atatu.com>, davem@...emloft.net
Cc:     netdev@...r.kernel.org, jhs@...jatatu.com,
        stephen@...workplumber.org, Jamal Hadi Salim <jhs@...atatu.com>
Subject: Re: [PATCH iproute2 1/1] tc: print raw qdisc handle.

Hello.

On 11/7/2016 5:16 AM, Roman Mashak wrote:

> Signed-off-by: Roman Mashak <mrv@...atatu.com>
> Signed-off-by: Jamal Hadi Salim <jhs@...atatu.com>
> ---
>  tc/tc_qdisc.c | 9 ++++++++-
>  1 file changed, 8 insertions(+), 1 deletion(-)
>
> diff --git a/tc/tc_qdisc.c b/tc/tc_qdisc.c
> index a63c476..9b06b8f 100644
> --- a/tc/tc_qdisc.c
> +++ b/tc/tc_qdisc.c
> @@ -238,7 +238,14 @@ int print_qdisc(const struct sockaddr_nl *who,
>  	if (n->nlmsg_type == RTM_DELQDISC)
>  		fprintf(fp, "deleted ");
>
> -	fprintf(fp, "qdisc %s %x: ", rta_getattr_str(tb[TCA_KIND]), t->tcm_handle>>16);
> +	if (!show_raw) {
> +	   fprintf(fp, "qdisc %s %x: ", rta_getattr_str(tb[TCA_KIND]),
> +			t->tcm_handle >> 16);
> +	} else {
> +	   fprintf(fp, "qdisc %s %x:[%08x] ", rta_getattr_str(tb[TCA_KIND]),
> +			t->tcm_handle >> 16, t->tcm_handle);

    The above/below code seems to indent with tabs only, why are you using spaces?

> +	}
> +
>  	if (filter_ifindex == 0)
>  		fprintf(fp, "dev %s ", ll_index_to_name(t->tcm_ifindex));
>  	if (t->tcm_parent == TC_H_ROOT)

MBR, Sergei

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ