From: Vincent Bernat <vincent@bernat•im>
To: David Ahern <dsahern@gmail•com>
Cc: netdev@vger•kernel.org, stephen@networkplumber•org,
serhe.popovych@gmail•com
Subject: Re: [PATCH iproute2-next] ipaddress: fix label matching
Date: Thu, 12 Jul 2018 07:08:03 +0200 [thread overview]
Message-ID: <m3sh4p3uto.fsf@luffy.cx> (raw)
In-Reply-To: <18bed3ed-4ad1-4506-6b80-62af9bd9e6d2@gmail.com> (David Ahern's message of "Wed, 11 Jul 2018 21:01:19 -0400")
❦ 11 juillet 2018 21:01 -0400, David Ahern <dsahern@gmail•com> :
>> +++ b/ip/ipaddress.c
>> @@ -837,11 +837,6 @@ int print_linkinfo(const struct sockaddr_nl *who,
>> if (!name)
>> return -1;
>>
>> - if (filter.label &&
>> - (!filter.family || filter.family == AF_PACKET) &&
>> - fnmatch(filter.label, name, 0))
>> - return -1;
>> -
>
> The offending commit changed the return code:
>
> if (filter.label &&
> (!filter.family || filter.family == AF_PACKET) &&
> - fnmatch(filter.label, RTA_DATA(tb[IFLA_IFNAME]), 0))
> - return 0;
> + fnmatch(filter.label, name, 0))
> + return -1;
>
>
> Vincent: can you try leaving the code as is, but change the return to 0?
Yes, it works by just returning 0. The code still doesn't make sense.
--
Many pages make a thick book, except for pocket Bibles which are on very
very thin paper.
next prev parent reply other threads:[~2018-07-12 5:15 UTC|newest]
Thread overview: 8+ messages / expand[flat|nested] mbox.gz Atom feed top
2018-07-11 11:36 [PATCH iproute2-next] ipaddress: fix label matching Vincent Bernat
2018-07-11 20:03 ` Stephen Hemminger
2018-07-11 20:26 ` Vincent Bernat
2018-07-12 1:01 ` David Ahern
2018-07-12 5:08 ` Vincent Bernat [this message]
2018-07-14 8:27 ` Serhey Popovych
2018-07-14 18:54 ` Serhey Popovych
2018-07-14 18:58 ` Vincent Bernat
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
Avoid top-posting and favor interleaved quoting:
https://en.wikipedia.org/wiki/Posting_style#Interleaved_style
* Reply using the --to, --cc, and --in-reply-to
switches of git-send-email(1):
git send-email \
--in-reply-to=m3sh4p3uto.fsf@luffy.cx \
--to=vincent@bernat$(echo .)im \
--cc=dsahern@gmail$(echo .)com \
--cc=netdev@vger$(echo .)kernel.org \
--cc=serhe.popovych@gmail$(echo .)com \
--cc=stephen@networkplumber$(echo .)org \
/path/to/YOUR_REPLY
https://kernel.org/pub/software/scm/git/docs/git-send-email.html
Be sure your reply has a Subject: header at the top and a blank line
before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox