Help: looking for equivalent syscall to shutdown() but for unix pipes

Alexandre Bique bique.alexandre@gmail.com
Fri Jan 18 19:26:00 GMT 2019


On Fri, Jan 18, 2019 at 8:22 PM Dmitry Goncharov
<dgoncharov@users.sf.net> wrote:
>
> On Thu, Jan 17, 2019 at 4:13 AM Alexandre Bique
> <bique.alexandre@gmail.com> wrote:
> > I'm not very enthusiast with the idea of sending an EOF message,
> > because the original producer comes from an other process, so there
> > could be all sorts of corrupted data over the pipe
>
> How is the pipe useful at all if there could be all sorts of corrupted data?
> Why don't you have stopConsumer close the write end of the pipe rather
> than the read end?

This doesn't even apply, let's consider that we don't have the file
descriptor to the write end of the pipe, we can't close it and we
can't write to it.
Let's assume that the write end of the pipe is owned by a process that
we can't modify and we know nothing about it.

-- 
Alexandre Bique



More information about the Libc-help mailing list