Reader: fix iteration logic.