[BRIDGE]: Lost call to br_fdb_fini() in br_init() error path
authorPavel Emelyanov <xemul@openvz.org>
Thu, 29 Nov 2007 12:41:43 +0000 (23:41 +1100)
committerHerbert Xu <herbert@gondor.apana.org.au>
Thu, 29 Nov 2007 12:41:43 +0000 (23:41 +1100)
In case the br_netfilter_init() (or any subsequent call)
fails, the br_fdb_fini() must be called to free the allocated
in br_fdb_init() br_fdb_cache kmem cache.

Signed-off-by: Pavel Emelyanov <xemul@openvz.org>
Signed-off-by: Herbert Xu <herbert@gondor.apana.org.au>
net/bridge/br.c

index 93867bb6cc978ca76c07c6de8bb31f55b0e8dc79..a9018287312071c4cd77a442b062b7444c7b72bf 100644 (file)
@@ -39,7 +39,7 @@ static int __init br_init(void)
 
        err = br_fdb_init();
        if (err)
-               goto err_out1;
+               goto err_out;
 
        err = br_netfilter_init();
        if (err)
@@ -65,6 +65,8 @@ err_out3:
 err_out2:
        br_netfilter_fini();
 err_out1:
+       br_fdb_fini();
+err_out:
        llc_sap_put(br_stp_sap);
        return err;
 }