UNIX FIFO: How to allow only one writer/reader pair to use a FIFO?
        Posted  
        
            by Max Krug
        on Stack Overflow
        
        See other posts from Stack Overflow
        
            or by Max Krug
        
        
        
        Published on 2010-05-30T14:44:11Z
        Indexed on 
            2010/05/30
            15:32 UTC
        
        
        Read the original article
        Hit count: 313
        
Hi!
I've written two programs: the first, the "writer", creates a FIFO and writes data into it. The second one, the "reader" runs in background and looks for data in the FIFO. Once data is there, the reader reads it out.
If I start e.g. two writers and two readers, they all can write/read into/from the same FIFO. How can I restrict it for 3rd and 4th readers/writers to use the FIFO and allow only one writer and one reader to use the FIFO?
thanks a lot.
-- kind regards, Max Krug
© Stack Overflow or respective owner