The following pull request was submitted through Github.
It can be accessed and reviewed at: https://github.com/lxc/lxd/pull/3256

This e-mail was sent by the LXC bot, direct replies will not reach the author
unless they happen to be subscribed to this list.

=== Description (from pull-request) ===
Signed-off-by: Christian Brauner <[email protected]>
From 76acb9021a7cc8ba491bb4bf28431ed798cd994b Mon Sep 17 00:00:00 2001
From: Christian Brauner <[email protected]>
Date: Sun, 30 Apr 2017 00:16:16 +0200
Subject: [PATCH] lxc copy: simplify

Signed-off-by: Christian Brauner <[email protected]>
---
 lxc/copy.go | 11 +----------
 1 file changed, 1 insertion(+), 10 deletions(-)

diff --git a/lxc/copy.go b/lxc/copy.go
index 95127c6..f380306 100644
--- a/lxc/copy.go
+++ b/lxc/copy.go
@@ -211,16 +211,7 @@ func (c *copyCmd) copyContainer(config *lxd.Config, 
sourceResource string, destR
         */
        waitchan := make(chan map[int]error, 2)
        wait := func(cli *lxd.Client, op string, ch chan map[int]error, 
senderid int) {
-               msg := make(map[int]error, 1)
-               err := cli.WaitForSuccess(op)
-               if err != nil {
-                       msg[senderid] = err
-                       ch <- msg
-                       return
-               }
-
-               msg[senderid] = nil
-               ch <- msg
+               ch <- map[int]error{senderid: cli.WaitForSuccess(op)}
        }
 
        var migrationErrFromClient error
_______________________________________________
lxc-devel mailing list
[email protected]
http://lists.linuxcontainers.org/listinfo/lxc-devel

Reply via email to