Linux Headquarters
[ Register ]
[ About us ] [ Home Page ]

[ Kernel ] [ Documentation ] [ Links ] [ Books ]

Kernel v2.1.100 /mm/mlock.c

Filename:/mm/mlock.c
Lines Added:2
Lines Deleted:2
Also changed in: (Previous) 2.1.89  2.1.45  2.1.43  2.1.23  2.1.17  2.1.6 
(Following) 2.1.101  2.1.106  2.1.108  2.1.130 

Location
[  2.1.100
  [  mm
     o  mlock.c

Patch

diff -u --recursive --new-file v2.1.99/linux/mm/mlock.c linux/mm/mlock.c
--- v2.1.99/linux/mm/mlock.c   Tue Mar 10 10:03:36 1998
+++ linux/mm/mlock.c   Wed May  6 10:56:06 1998
@@ -144,7 +144,7 @@
    struct vm_area_struct * vma, * next;
    int error;
 
-   if (!suser())
+   if (!capable(CAP_IPC_LOCK))
       return -EPERM;
    len = (len + ~PAGE_MASK) & PAGE_MASK;
    end = start + len;
@@ -235,7 +235,7 @@
    unsigned int def_flags;
    struct vm_area_struct * vma;
 
-   if (!suser())
+   if (!capable(CAP_IPC_LOCK))
       return -EPERM;
 
    def_flags = 0;


Comments: webmaster (at) linuxhq.com.
Advertising: banners (at) linuxhq.com.
Compilation ©1998-2008 Linux Headquarters, Inc.