С одной стороны, man epoll, A9:
For  stream-oriented  files  (e.g.,  pipe,  FIFO,   stream
socket),  the  condition  that the read/write I/O space is
exhausted can also be detected by checking the  amount  of
data  read  from  / written to the target file descriptor.
For example, if you call read(2) by asking to read a  cer‐
tain  amount of data and read(2) returns a lower number of
bytes, you can be sure of having exhausted  the  read  I/O
space  for  the  file  descriptor.   The same is true when
writing using write(2).  (Avoid this latter  technique  if
you  cannot  guarantee  that the monitored file descriptor
always refers to a stream-oriented file.)
If  a  write()  is  interrupted by a signal handler before any
bytes are written, then the call fails with the  error  EINTR;
if it is interrupted after at least one byte has been written,
the call succeeds, and returns the number of bytes written.
Получается, что я не могу надёжно использовать технологию в A9, например, с пайпами? plain file является stream-oriented? а файл с O_APPEND? send() и splice() ничего не говорит насчёт поведения в случае когда и послать-то послал, и сигнал-то пришёл. Как быть? кому доверять?
Вариант с блокировкой сигналов на это время не предлагать. сам так делаю, но это же хак для этого случая.
UPD. send() косвенно говорит, что EINTR придёт только если совсем ничего не послал. а вот splice() не говорит....



