lkml.org 
[lkml]   [1999]   [Mar]   [15]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRE: [patch] bugfix for fs/proc/array.c FIXME tasklist_lock
On Mon, 15 Mar 1999, Tigran Aivazian wrote:

> There are many regular files in /proc. Many of them contain data that
> can be treated as "record oriented". But they are not, because it was
> easy enough to implement them as proper regular files (i.e. a stream
> of bytes, NO records).

Try reading/writing them a byte at a time some day. For instance:

dd if=/proc/sys/kernel/modprobe of=/tmp/out bs=1 count=20
cat /proc/sys/kernel/modprobe

These give different results for me. This is a more serious problem than
the one you are complaining about.

> For /proc/<pid>/maps it is not easy to do that. And now you tell me
> that it is "intentional"? No, its just an excuse, although a valid and
> good one. Good, but not perfect. Yet Linux is.

If your program can't cope with read() returning less data than you asked
for even though more exists, your program needs fixing. man 2 read.

Tim.
*/


-
To unsubscribe from this list: send the line "unsubscribe linux-kernel" in
the body of a message to majordomo@vger.rutgers.edu
Please read the FAQ at http://www.tux.org/lkml/

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