moved the read

i think the read error is being because file is in use