Ensure that readRows and readLines stream implementations close their underlying instance at most once.