Type: Posts; User: Click_here
I don't see where you are closing file_name1 before trying to open it again in read mode.