]> git.baikalelectronics.ru Git - kernel.git/commit
bridge: Fix return values of br_multicast_add_group/br_multicast_new_group
authorTobias Klauser <tklauser@distanz.ch>
Fri, 10 Dec 2010 03:18:04 +0000 (03:18 +0000)
committerDavid S. Miller <davem@davemloft.net>
Fri, 10 Dec 2010 21:00:39 +0000 (13:00 -0800)
commit4ac3f2cde81110d352c37fb005d43c6a12308c02
tree9f93e17facfe15540e51e3b29b6ca0f21a0d235f
parentcd05bd7d7d4341e0889456f51349eaeac14b5d4d
bridge: Fix return values of br_multicast_add_group/br_multicast_new_group

If br_multicast_new_group returns NULL, we would return 0 (no error) to
the caller of br_multicast_add_group, which is not what we want. Instead
br_multicast_new_group should return ERR_PTR(-ENOMEM) in this case.
Also propagate the error number returned by br_mdb_rehash properly.

Signed-off-by: Tobias Klauser <tklauser@distanz.ch>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/bridge/br_multicast.c