cfg80211: fix crash in cfg80211_set_freq()
[safe/jmp/linux-2.6] / net / econet / af_econet.c
index 5e9426a..2a5a805 100644 (file)
@@ -30,6 +30,7 @@
 #include <linux/wireless.h>
 #include <linux/skbuff.h>
 #include <linux/udp.h>
+#include <linux/slab.h>
 #include <net/sock.h>
 #include <net/inet_common.h>
 #include <linux/stat.h>
@@ -605,13 +606,14 @@ static struct proto econet_proto = {
  *     Create an Econet socket
  */
 
-static int econet_create(struct net *net, struct socket *sock, int protocol)
+static int econet_create(struct net *net, struct socket *sock, int protocol,
+                        int kern)
 {
        struct sock *sk;
        struct econet_sock *eo;
        int err;
 
-       if (net != &init_net)
+       if (!net_eq(net, &init_net))
                return -EAFNOSUPPORT;
 
        /* Econet only provides datagram services. */