浏览代码

Adding workaround to suppress gofmt issues with api/client/utils.go

Signed-off-by: Don Kjer <don.kjer@gmail.com>
Don Kjer 10 年之前
父节点
当前提交
33b931e718
共有 1 个文件被更改,包括 4 次插入1 次删除
  1. 4 1
      api/client/utils.go

+ 4 - 1
api/client/utils.go

@@ -260,7 +260,10 @@ func (cli *DockerCli) monitorTtySize(id string, isExec bool) error {
 	sigchan := make(chan os.Signal, 1)
 	gosignal.Notify(sigchan, signal.SIGWINCH)
 	go func() {
-		for _ = range sigchan {
+		// This tmp := range..., _ = tmp workaround is needed to
+		// suppress gofmt warnings while still preserve go1.3 compatibility
+		for tmp := range sigchan {
+			_ = tmp
 			cli.resizeTty(id, isExec)
 		}
 	}()