浏览代码

actually run v2ctl

Darien Raymond 8 年之前
父节点
当前提交
e69e6d00cb
共有 1 个文件被更改,包括 10 次插入1 次删除
  1. 10 1
      main/config_json.go

+ 10 - 1
main/config_json.go

@@ -26,7 +26,16 @@ func jsonToProto(input io.Reader) (*core.Config, error) {
 		return nil, err
 	}
 	defer stdoutReader.Close()
-	return core.LoadConfig(core.ConfigFormat_Protobuf, stdoutReader)
+
+	if err := cmd.Start(); err != nil {
+		return nil, err
+	}
+
+	config, err := core.LoadConfig(core.ConfigFormat_Protobuf, stdoutReader)
+
+	cmd.Wait()
+
+	return config, err
 }
 
 func init() {