Files
linux-legacy/net
Eric Dumazet d65e5e5853 net: Fix the rollback test in dev_change_name()
[ Upstream commit 91e9c07bd635353d1a278bdb38dbb56ac371bcb8 ]

net: Fix the rollback test in dev_change_name()

In dev_change_name() an err variable is used for storing the original
call_netdevice_notifiers() errno (negative) and testing for a rollback
error later, but the test for non-zero is wrong, because the err might
have positive value as well - from dev_alloc_name(). It means the
rollback for a netdevice with a number > 0 will never happen. (The err
test is reordered btw. to make it more readable.)

Signed-off-by: Jarek Poplawski <jarkao2@gmail.com>
Signed-off-by: Eric Dumazet <eric.dumazet@gmail.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
Signed-off-by: Greg Kroah-Hartman <gregkh@suse.de>
2009-12-18 13:43:56 -08:00
..
2009-05-25 01:53:53 -07:00
2009-10-12 12:40:31 -07:00
2009-01-04 17:29:21 -08:00
2009-08-06 13:08:40 -07:00
2009-05-25 01:53:53 -07:00
2009-12-08 10:22:01 -08:00
2009-07-12 12:22:34 -07:00
2009-08-23 22:55:51 -07:00
2009-08-17 18:05:32 -07:00
2009-08-05 12:14:09 -07:00
2009-12-08 10:21:46 -08:00
2009-08-06 13:08:38 -07:00
2009-12-08 10:22:01 -08:00
2009-12-18 13:43:32 -08:00
2009-07-12 12:22:34 -07:00
2009-07-12 12:22:34 -07:00