管道的使用——mkfifo

 

A process can open a FIFO in non-blocking mode. In this case,

opening for read only will succeed even if no-one has opened on the write side yet;

opening for write only will fail with ENXIO (no such device or address) unless the other end has already been opened.

 

在non-blocking模式下,进程可以用只读模式打开管道(即便另一端没有用写模式打开);

但是不能用只写模式打开管道(错误为ENXIO, no such device or address),除非另一端已经用读模式打开了。

 

 

你可能感兴趣的:(管道的使用——mkfifo)