From mboxrd@z Thu Jan 1 00:00:00 1970 From: David Ahern Subject: Re: [PATCH iproute2-next] ipaddress: fix label matching Date: Wed, 11 Jul 2018 21:01:19 -0400 Message-ID: <18bed3ed-4ad1-4506-6b80-62af9bd9e6d2@gmail.com> References: <20180711113603.16589-1-vincent@bernat.im> Mime-Version: 1.0 Content-Type: text/plain; charset=utf-8 Content-Transfer-Encoding: 7bit To: Vincent Bernat , netdev@vger.kernel.org, stephen@networkplumber.org, serhe.popovych@gmail.com Return-path: Received: from mail-pg1-f194.google.com ([209.85.215.194]:35188 "EHLO mail-pg1-f194.google.com" rhost-flags-OK-OK-OK-OK) by vger.kernel.org with ESMTP id S1733236AbeGLBIU (ORCPT ); Wed, 11 Jul 2018 21:08:20 -0400 Received: by mail-pg1-f194.google.com with SMTP id e6-v6so3381620pgv.2 for ; Wed, 11 Jul 2018 18:01:23 -0700 (PDT) In-Reply-To: <20180711113603.16589-1-vincent@bernat.im> Content-Language: en-US Sender: netdev-owner@vger.kernel.org List-ID: On 7/11/18 7:36 AM, Vincent Bernat wrote: > diff --git a/ip/ipaddress.c b/ip/ipaddress.c > index 5009bfe6d2e3..20ef6724944e 100644 > --- a/ip/ipaddress.c > +++ 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?