浏览代码

RemoteConsole: prevent null access on connections

Yuxiao Mao 7 月之前
父节点
当前提交
7bcfa59600
共有 1 个文件被更改,包括 1 次插入0 次删除
  1. 1 0
      hrt/impl/RemoteConsole.hx

+ 1 - 0
hrt/impl/RemoteConsole.hx

@@ -27,6 +27,7 @@ class RemoteConsole {
 	public function new( ?port : Int, ?host : String ) {
 		this.host = host ?? DEFAULT_HOST;
 		this.port = port ?? DEFAULT_PORT;
+		this.connections = [];
 	}
 
 	public function startServer( ?onClient : RemoteConsoleConnection->Void ) {