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] [thread-next>] [day] [month] [year] [list]
Message-ID: <Y40hjAoN4VcUCatp@DEN-LT-70577>
Date:   Sun, 4 Dec 2022 22:27:40 +0000
From:   <Daniel.Machon@...rochip.com>
To:     <stephen@...workplumber.org>
CC:     <netdev@...r.kernel.org>, <dsahern@...nel.org>, <petrm@...dia.com>,
        <maxime.chevallier@...tlin.com>, <vladimir.oltean@....com>,
        <UNGLinuxDriver@...rochip.com>
Subject: Re: [PATCH iproute2-next v3 1/2] dcb: add new pcp-prio parameter to
 dcb app

> EXTERNAL EMAIL: Do not click links or open attachments unless you know the content is safe
> 
> On Fri, 2 Dec 2022 10:22:34 +0100
> Daniel Machon <daniel.machon@...rochip.com> wrote:
> 
> > +static int dcb_app_print_key_pcp(__u16 protocol)
> > +{
> > +     /* Print in numerical form, if protocol value is out-of-range */
> > +     if (protocol > DCB_APP_PCP_MAX) {
> > +             fprintf(stderr, "Unknown PCP key: %d\n", protocol);
> > +             return print_uint(PRINT_ANY, NULL, "%d:", protocol);
> > +     }
> > +
> > +     return print_string(PRINT_ANY, NULL, "%s:", pcp_names[protocol]);
> > +}
> 
> This is not an application friendly way to produce JSON output.
> You need to put a key on each one, and value should not contain colon.

Hi Stephen,

Trying to understand your comment.

Are you talking about not producing any JSON output with the symbolic
PCP values? eg. ["1de", 1] -> [8, 1]. So basically print with PRINT_FP
in case of printing in JSON context?

/Daniel

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ