lkml.org 
[lkml]   [2004]   [May]   [24]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Subject[PATCH] msync shouldn't go over bss sections
From
Date
This changes the behaviour of msync_interval() to make it impossible to
try to sys_msync() anything not file mapped.


--- mm/msync_orig.c 2004-05-23 21:31:32.000000000 +0200
+++ mm/msync.c 2004-05-24 16:10:24.000000000 +0200
@@ -137,7 +137,7 @@ static int filemap_sync(struct vm_area_s
static int msync_interval(struct vm_area_struct * vma,
unsigned long start, unsigned long end, int flags)
{
- int ret = 0;
+ int ret = -ENOMEM;
struct file * file = vma->vm_file;

if ((flags & MS_INVALIDATE) && (vma->vm_flags & VM_LOCKED))
-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.kernel.org
More majordomo info at http://vger.kernel.org/majordomo-info.html
Please read the FAQ at http://www.tux.org/lkml/

\
 
 \ /
  Last update: 2005-03-22 14:03    [W:0.056 / U:0.028 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site