lkml.org 
[lkml]   [2003]   [Nov]   [28]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
Patch in this message
/
Date
From
SubjectRe: [BUG] scheduling while atomic when lseek()ing in /proc/net/tcp
Tore Anderson wrote:

> Hi,
>
> The following code instantly freezes my all of my machines running
> any of the beavers:
>
>
The following patch fixed this, but i am _not_not_not sure whether this
is the right way to do.
Any ideas folks ?

/Raj




--- seq_file.c.org 2003-11-28 11:12:28.000000000 +0530
+++ seq_file.c 2003-11-28 11:44:44.968883784 +0530
@@ -213,6 +213,9 @@
switch (origin) {
case 1:
offset += file->f_pos;
+ if(offset >= 0)
+ retval = file->f_pos = offset;
+ break;
case 0:
if (offset < 0)
break;
\
 
 \ /
  Last update: 2005-03-22 13:58    [W:0.057 / U:0.196 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site