fixing the mutex in the fifo queue