fix copy file bug