X-Git-Url: http://pilppa.org/gitweb/?a=blobdiff_plain;ds=sidebyside;f=ipc%2Fshm.c;h=940b0c9b13aab7c33159760bba2a3a53756779dd;hb=14fef6414be49d59f4784eeef8d9c3f468993205;hp=8098968519026406191014b4cb64ee870e2a721c;hpb=1465887cfe79889273e3fd3aaf862e7ec3ee244f;p=linux-2.6-omap-h63xx.git diff --git a/ipc/shm.c b/ipc/shm.c index 80989685190..940b0c9b13a 100644 --- a/ipc/shm.c +++ b/ipc/shm.c @@ -17,7 +17,6 @@ * Dustin Kirkland */ -#include #include #include #include @@ -643,7 +642,7 @@ asmlinkage long sys_shmctl (int shmid, int cmd, struct shmid_ds __user *buf) err = audit_ipc_obj(&(shp->shm_perm)); if (err) goto out_unlock_up; - err = audit_ipc_set_perm(0, setbuf.uid, setbuf.gid, setbuf.mode, &(shp->shm_perm)); + err = audit_ipc_set_perm(0, setbuf.uid, setbuf.gid, setbuf.mode); if (err) goto out_unlock_up; err=-EPERM; @@ -698,7 +697,6 @@ long do_shmat(int shmid, char __user *shmaddr, int shmflg, ulong *raddr) int err; unsigned long flags; unsigned long prot; - unsigned long o_flags; int acc_mode; void *user_addr; @@ -725,11 +723,9 @@ long do_shmat(int shmid, char __user *shmaddr, int shmflg, ulong *raddr) if (shmflg & SHM_RDONLY) { prot = PROT_READ; - o_flags = O_RDONLY; acc_mode = S_IRUGO; } else { prot = PROT_READ | PROT_WRITE; - o_flags = O_RDWR; acc_mode = S_IRUGO | S_IWUGO; } if (shmflg & SHM_EXEC) {