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]
Date:   Thu, 11 Apr 2019 10:55:06 -0700
From:   Song Liu <liu.song.a23@...il.com>
To:     Quentin Monnet <quentin.monnet@...ronome.com>
Cc:     Benjamin Poirier <bpoirier@...e.com>,
        Daniel Borkmann <daniel@...earbox.net>,
        Networking <netdev@...r.kernel.org>, bpf <bpf@...r.kernel.org>,
        David Ahern <dsahern@...il.com>
Subject: Re: [PATCH bpf] bpftool: Fix errno variable usage

On Thu, Apr 11, 2019 at 4:23 AM Quentin Monnet
<quentin.monnet@...ronome.com> wrote:
>
> 2019-04-11 17:03 UTC+0900 ~ Benjamin Poirier <bpoirier@...e.com>
> > The test meant to use the saved value of errno. Given the current code, it
> > makes no practical difference however.
> >
> > Fixes: bf598a8f0f77 ("bpftool: Improve handling of ENOENT on map dumps")
> > Signed-off-by: Benjamin Poirier <bpoirier@...e.com>

Acked-by: Song Liu <songliubraving@...com>

> > ---
> >  tools/bpf/bpftool/map.c | 2 +-
> >  1 file changed, 1 insertion(+), 1 deletion(-)
> >
> > diff --git a/tools/bpf/bpftool/map.c b/tools/bpf/bpftool/map.c
> > index e0c650d91784..05b029b934a6 100644
> > --- a/tools/bpf/bpftool/map.c
> > +++ b/tools/bpf/bpftool/map.c
> > @@ -720,7 +720,7 @@ static int dump_map_elem(int fd, void *key, void *value,
> >               jsonw_string_field(json_wtr, "error", strerror(lookup_errno));
> >               jsonw_end_object(json_wtr);
> >       } else {
> > -             if (errno == ENOENT)
> > +             if (lookup_errno == ENOENT)
> >                       print_entry_plain(map_info, key, NULL);
> >               else
> >                       print_entry_error(map_info, key,
> >
>
>
> Reviewed-by: Quentin Monnet <quentin.monnet@...ronome.com>

Powered by blists - more mailing lists

Powered by Openwall GNU/*/Linux Powered by OpenVZ