[<prev] [next>] [<thread-prev] [thread-next>] [day] [month] [year] [list]
Message-Id: <20171115.140825.914229125688524224.davem@davemloft.net>
Date: Wed, 15 Nov 2017 14:08:25 +0900 (KST)
From: David Miller <davem@...emloft.net>
To: cugyly@....com
Cc: netdev@...r.kernel.org, Linyu.Yuan@...atel-sbell.com.cn
Subject: Re: [PATCH net-next] net: assign err to 0 at begin in do_setlink()
function
From: yuan linyu <cugyly@....com>
Date: Tue, 14 Nov 2017 22:30:59 +0800
> From: yuan linyu <Linyu.Yuan@...atel-sbell.com.cn>
>
> each netlink attribute have proper process when error happen,
> when exit on attribute process, it implies that no error,
> so err = 0; is useless.
>
> assign err = 0; at beginning if all attributes not set.
>
> Signed-off-by: yuan linyu <Linyu.Yuan@...atel-sbell.com.cn>
This change is not correct.
The IFLA_VF_PORTS code block can finish with err set non-zero.
The assignment to zero there is really necessary.
Powered by blists - more mailing lists