finish read and write