lkml.org 
[lkml]   [2001]   [Feb]   [13]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
From
SubjectRe: Linux 2.2.19pre10
Date
Hi Alan,

On Tue, 13 Feb 2001, Alan Cox wrote:
>> Yes, I understand that. But I never got any note that my fix is
>> broken and I still do not understand what's the concern.
>
> Unless Im misreading the code the segment you poke at has
> potentially been freed before it is written too.

Oh yes I was blind, shame on me. Here comes a fixed version.

Greetings
Christoph

--- 2.2.19-pre10/ipc/shm.c.orig Tue Feb 13 14:35:25 2001
+++ 2.2.19-pre10/ipc/shm.c Tue Feb 13 14:34:49 2001
@@ -337,6 +337,8 @@
if (current->euid == shp->u.shm_perm.uid ||
current->euid == shp->u.shm_perm.cuid ||
capable(CAP_SYS_ADMIN)) {
+ /* Do not find it any more */
+ shp->u.shm_perm.key = IPC_PRIVATE;
shp->u.shm_perm.mode |= SHM_DEST;
if (shp->u.shm_nattch <= 0)
killseg (id);
-
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 13:14    [W:0.106 / U:0.016 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site