Linux kernel mirror (for testing) git.kernel.org/pub/scm/linux/kernel/git/torvalds/linux.git
kernel os linux
1
fork

Configure Feed

Select the types of activity you want to include in your feed.

Merge branch 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6

* 'for-linus' of git://git.kernel.org/pub/scm/linux/kernel/git/jmorris/security-testing-2.6:
selinux: Fix a panic in selinux_netlbl_inode_permission()

+3 -2
+3 -2
security/selinux/netlabel.c
··· 386 386 if (!S_ISSOCK(inode->i_mode) || 387 387 ((mask & (MAY_WRITE | MAY_APPEND)) == 0)) 388 388 return 0; 389 - 390 389 sock = SOCKET_I(inode); 391 390 sk = sock->sk; 391 + if (sk == NULL) 392 + return 0; 392 393 sksec = sk->sk_security; 393 - if (sksec->nlbl_state != NLBL_REQUIRE) 394 + if (sksec == NULL || sksec->nlbl_state != NLBL_REQUIRE) 394 395 return 0; 395 396 396 397 local_bh_disable();