]> git.hungrycats.org Git - linux/commitdiff
[IPV4]: Handle kmem_cache_create() failure in ipmr.c
authorWalter Harms <wharms@bfs.de>
Mon, 23 Feb 2004 07:10:06 +0000 (23:10 -0800)
committerDavid S. Miller <davem@kernel.bkbits.net>
Mon, 23 Feb 2004 07:10:06 +0000 (23:10 -0800)
net/ipv4/ipmr.c

index a3720f2f8014779768fea55ba4a99983ffb8c548..ca7e1e57e44b4e95dc062fa86e61753af675e726 100644 (file)
@@ -1892,6 +1892,9 @@ void __init ip_mr_init(void)
                                       sizeof(struct mfc_cache),
                                       0, SLAB_HWCACHE_ALIGN,
                                       NULL, NULL);
+       if (!mrt_cachep)
+               panic("cannot allocate ip_mrt_cache");
+
        init_timer(&ipmr_expire_timer);
        ipmr_expire_timer.function=ipmr_expire_process;
        register_netdevice_notifier(&ip_mr_notifier);