aboutsummaryrefslogtreecommitdiffstats
path: root/security/selinux/netif.c
diff options
context:
space:
mode:
authorAnton Altaparmakov <aia21@cantab.net>2005-10-31 05:06:46 -0500
committerAnton Altaparmakov <aia21@cantab.net>2005-10-31 05:06:46 -0500
commit1f04c0a24b2f3cfe89c802a24396263623e3512d (patch)
treed7e2216b6e65b833c0c2b79b478d13ce17dbf296 /security/selinux/netif.c
parent07b188ab773e183871e57b33ae37bf635c9f12ba (diff)
parente2f2e58e7968f8446b1078a20a18bf8ea12b4fbc (diff)
Merge branch 'master' of /usr/src/ntfs-2.6/
Diffstat (limited to 'security/selinux/netif.c')
-rw-r--r--security/selinux/netif.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/security/selinux/netif.c b/security/selinux/netif.c
index 718d7be9f4dd..b10c34e8a743 100644
--- a/security/selinux/netif.c
+++ b/security/selinux/netif.c
@@ -114,13 +114,12 @@ static struct sel_netif *sel_netif_lookup(struct net_device *dev)
114 if (likely(netif != NULL)) 114 if (likely(netif != NULL))
115 goto out; 115 goto out;
116 116
117 new = kmalloc(sizeof(*new), GFP_ATOMIC); 117 new = kzalloc(sizeof(*new), GFP_ATOMIC);
118 if (!new) { 118 if (!new) {
119 netif = ERR_PTR(-ENOMEM); 119 netif = ERR_PTR(-ENOMEM);
120 goto out; 120 goto out;
121 } 121 }
122 122
123 memset(new, 0, sizeof(*new));
124 nsec = &new->nsec; 123 nsec = &new->nsec;
125 124
126 ret = security_netif_sid(dev->name, &nsec->if_sid, &nsec->msg_sid); 125 ret = security_netif_sid(dev->name, &nsec->if_sid, &nsec->msg_sid);