etcdctl/command: fix shawdowed error variable
This fixes https://github.com/coreos/etcd/issues/3954.
This commit is contained in:
@ -61,7 +61,7 @@ func handleBackup(c *cli.Context) {
|
||||
if snapshot != nil {
|
||||
walsnap.Index, walsnap.Term = snapshot.Metadata.Index, snapshot.Metadata.Term
|
||||
newss := snap.New(destSnap)
|
||||
if err := newss.SaveSnap(*snapshot); err != nil {
|
||||
if err = newss.SaveSnap(*snapshot); err != nil {
|
||||
log.Fatal(err)
|
||||
}
|
||||
}
|
||||
|
Reference in New Issue
Block a user