lkml.org 
[lkml]   [2009]   [Jul]   [6]   [last100]   RSS Feed
Views: [wrap][no wrap]   [headers]  [forward] 
 
Messages in this thread
/
Date
From
SubjectRe: PROPOSAL: extend pipe() to support NULL argument.
Changli Gao a écrit :
> On Mon, Jul 6, 2009 at 2:15 PM, Albert ARIBAUD<albert.aribaud@free.fr> wrote:
>>>
>>> pipe doesn't support llseek.
>> I wasn't thinking of actively seeking a file position, but simply that reads
>> and writes were independent (and both variable) in size, thus even without
>> (l)seeking, each endpoint has an independent read (resp. write) position to
>> track what's been read from (resp.written into) it at any time, and such a
>> position is, IIUC, single for a given fd, making a fd (a struct file)
>> insufficient for representing a pipe.
>>
>> Amicalement,
>> --
>> Albert.
>>
> pipe doesn't refer to pos when reading or writing. Please refer to
> pipe_read() and pipe_write() for more detail.

Hmm. Then how does pipe avoid overwriting what it's already written at the
in endpoint, or reading twice the same data from the out endpoint?

Amicalement,
--
Albert.
--
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: 2009-07-06 08:35    [W:0.042 / U:0.248 seconds]
©2003-2020 Jasper Spaans|hosted at Digital Ocean and TransIP|Read the blog|Advertise on this site