Fix error on copying file.