fix copyFile error message
Signed-off-by: sakeven <jc5930@sina.cn>
This commit is contained in:
parent
696e88c813
commit
0e2822f892
1 changed files with 2 additions and 2 deletions
|
@ -107,12 +107,12 @@ func copyDirectory(dst, src string, inodes map[uint64]string) error {
|
|||
func copyFile(source, target string) error {
|
||||
src, err := os.Open(source)
|
||||
if err != nil {
|
||||
return errors.Wrapf(err, "failed to open source %s", err)
|
||||
return errors.Wrapf(err, "failed to open source %s", source)
|
||||
}
|
||||
defer src.Close()
|
||||
tgt, err := os.Create(target)
|
||||
if err != nil {
|
||||
return errors.Wrapf(err, "failed to open target %s", err)
|
||||
return errors.Wrapf(err, "failed to open target %s", target)
|
||||
}
|
||||
defer tgt.Close()
|
||||
|
||||
|
|
Loading…
Reference in a new issue