readonly is supposed to prevent the user from modifying the buffer and it can be useful to generate a readonly fifo buffer. Fixes #3398