main/buffers: take into account FRONT_AND_BACK on ReadBuffer