Added ability to work with fifo.