fix bug

not to open 2 files at the same time in ssh