On Sun, Dec 07, 2003 at 12:35:06AM +0100, Andreas Goesele wrote: > Mark C <[EMAIL PROTECTED]> writes: > > > same here from the debian sources, but with a few added patches, > > there is no need to download a new kernel, just get the source you have > > for the currently running kernel, apply this patch: > > > > ---------------------- cut --------------------- > > --- 1.31/mm/mmap.c Fri Sep 12 06:44:06 2003 > > +++ 1.32/mm/mmap.c Thu Oct 2 01:18:19 2003 > > @@ -1041,6 +1041,9 @@ > > if (!len) > > return addr; > > > > + if ((addr + len) > TASK_SIZE || (addr + len) < addr) > > + return -EINVAL; > > + > > /* > > * mlock MCL_FUTURE? > > */ > > ---------------------- cut --------------------- > > > > and recompile, this was taken originally from, Debian Planet. > > With 2.4.21 I get: > > $ patch -p1 < mm.patch > patching file mm/mmap.c > Hunk #1 FAILED at 1041. > 1 out of 1 hunk FAILED -- saving rejects to file mm/mmap.c.rej > > In mmap.c.rej I find: > > > ************** > *** 1041,1046 **** > if (!len) > return addr; > > /* > * mlock MCL_FUTURE? > */ > --- 1041,1049 ---- > if (!len) > return addr; > > + if ((addr + len) > TASK_SIZE || (addr + len) < addr) > + return -EINVAL; > + > /* > * mlock MCL_FUTURE? > */ > > What am I doing wrong? > > Andreas Goesele > > -- > Omnis enim res, quae dando non deficit, dum habetur et non datur, > nondum habetur, quomodo habenda est. > Augustinus, De doctrina christiana > I would like to apply this patch but have no idea how to do it. I frequently compile kernels from the already patched kernel-source's so kernel-source-2.4.22 is on hand. Are there instructions somewhere which show step-by-step how and where to insert the above instructions?
Tom George > > -- > To UNSUBSCRIBE, email to [EMAIL PROTECTED] > with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED] -- To UNSUBSCRIBE, email to [EMAIL PROTECTED] with a subject of "unsubscribe". Trouble? Contact [EMAIL PROTECTED]

