diff options
Diffstat (limited to 'ipc/shm.c')
-rw-r--r-- | ipc/shm.c | 3 |
1 files changed, 1 insertions, 2 deletions
@@ -764,8 +764,7 @@ SYSCALL_DEFINE3(shmctl, int, shmid, int, cmd, struct shmid_ds __user *, buf) | |||
764 | if (euid != shp->shm_perm.uid && | 764 | if (euid != shp->shm_perm.uid && |
765 | euid != shp->shm_perm.cuid) | 765 | euid != shp->shm_perm.cuid) |
766 | goto out_unlock; | 766 | goto out_unlock; |
767 | if (cmd == SHM_LOCK && | 767 | if (cmd == SHM_LOCK && !rlimit(RLIMIT_MEMLOCK)) |
768 | !current->signal->rlim[RLIMIT_MEMLOCK].rlim_cur) | ||
769 | goto out_unlock; | 768 | goto out_unlock; |
770 | } | 769 | } |
771 | 770 | ||