Skip to content

Commit

Permalink
Merge pull request etcd-io#264 from zouyee/instead
Browse files Browse the repository at this point in the history
Use WriteTo() instead
  • Loading branch information
ptabor authored Mar 16, 2021
2 parents 8f715c0 + cc6381f commit 6565e9d
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion tx.go
Original file line number Diff line number Diff line change
Expand Up @@ -393,7 +393,7 @@ func (tx *Tx) CopyFile(path string, mode os.FileMode) error {
return err
}

err = tx.Copy(f)
_, err = tx.WriteTo(f)
if err != nil {
_ = f.Close()
return err
Expand Down

0 comments on commit 6565e9d

Please sign in to comment.