浏览代码

hxd.net.Socket: do not throw not catchable error

Yuxiao Mao 7 月之前
父节点
当前提交
a982273270
共有 1 个文件被更改,包括 1 次插入1 次删除
  1. 1 1
      hxd/net/Socket.hx

+ 1 - 1
hxd/net/Socket.hx

@@ -118,7 +118,7 @@ class Socket {
 			onConnect(s);
 		}).on('error', function(e) {
 			close();
-			throw e;
+			onError(e);
 		}).listen(port, host, listenCount);
 		#else
 		throw "Not implemented";