diff options
author | Jeff Garzik <jeff@garzik.org> | 2006-04-18 10:54:00 +0200 |
---|---|---|
committer | Jeff Garzik <jeff@garzik.org> | 2006-04-18 10:54:00 +0200 |
commit | 4741c336d27dec3ea68a35659abb8dc82b142388 (patch) | |
tree | a8576df82129354b77b0144c480c446ec7aba7b2 /ipc/shm.c | |
parent | [PATCH] sata_sil24: enable 64bit (diff) | |
parent | [PATCH] IPC: access to unmapped vmalloc area in grow_ary() (diff) | |
download | linux-4741c336d27dec3ea68a35659abb8dc82b142388.tar.xz linux-4741c336d27dec3ea68a35659abb8dc82b142388.zip |
Merge branch 'master'
Diffstat (limited to 'ipc/shm.c')
-rw-r--r-- | ipc/shm.c | 2 |
1 files changed, 2 insertions, 0 deletions
diff --git a/ipc/shm.c b/ipc/shm.c index 6b0c9af5bbf7..1c2faf62bc73 100644 --- a/ipc/shm.c +++ b/ipc/shm.c @@ -162,6 +162,8 @@ static int shm_mmap(struct file * file, struct vm_area_struct * vma) ret = shmem_mmap(file, vma); if (ret == 0) { vma->vm_ops = &shm_vm_ops; + if (!(vma->vm_flags & VM_WRITE)) + vma->vm_flags &= ~VM_MAYWRITE; shm_inc(file->f_dentry->d_inode->i_ino); } |