简体   繁体   English

socket.io在firefox中抛出NS_ERROR_NOT_CONNECTED

[英]socket.io throws NS_ERROR_NOT_CONNECTED in firefox

Some of our windows users are experiencing trouble with socket.io while using Firefox 12. One person was using XP, the other Vista. 我们的一些Windows用户在使用Firefox 12时遇到socket.io的问题。一个人使用XP,另一个人使用Vista。 Firefox 13 is fine. Firefox 13很好。

uncaught exception: [
  Exception... "Component returned failure code: 0x804b000c (NS_ERROR_NOT_CONNECTED)" 
  nsresult: "0x804b000c (NS_ERROR_NOT_CONNECTED)"
  location: "JS frame :: ...socket.io.js :: :: line 2" data: no
]

The error is occurring on the second line of the socket.io client js file. 该错误发生在socket.io客户端js文件的第二行。 I am not sure if this error occurs persistently in FF12 or sporadicly. 我不确定这个错误是在FF12中持续发生还是偶尔发生。 The person that reported this problem to me is seeing it persistently. 向我报告此问题的人持续看到它。

The closest thing I found was: https://bugzilla.mozilla.org/show_bug.cgi?id=732363 . 我发现最接近的是: https//bugzilla.mozilla.org/show_bug.cgi?id = 732363 Which leads me to believe it is a fug in FF. 这让我相信它是FF的一个诱惑。 But I'm not sure. 但我不确定。

Is this a bug in FF? 这是FF中的错误吗? Or could it be in my code? 或者它可能在我的代码中? If the latter, what type of code might be causing this? 如果是后者,可能会导致什么类型的代码?

If you try forcing another transport protocol, such as xhr-polling by changing transports on the node server where you initiate socket.io. 如果尝试通过更改启动socket.io的节点服务器上的传输来强制执行其他传输协议,例如xhr-polling

io.set('transports', ['websocket','xhr-polling','jsonp-polling']);

Try with one at a time. 一次尝试一个。 Begin from the bottom and work yourself up. 从底部开始,努力工作。

I am not being sure, by far, just suggesting to test because I have had many strange browser/socket issues related to transport. 到目前为止,我不确定只是建议进行测试,因为我有许多与传输相关的奇怪的浏览器/套接字问题。

The worst problems has been with clients thinking they can do flashsocket and it ultimately fails, hence my transports look like the above rather than the "default". 最糟糕的问题是客户认为他们可以做flashsocket并最终失败,因此我的传输看起来像上面而不是“默认”。

声明:本站的技术帖子网页,遵循CC BY-SA 4.0协议,如果您需要转载,请注明本站网址或者原文地址。任何问题请咨询:yoyou2525@163.com.

 
粤ICP备18138465号  © 2020-2024 STACKOOM.COM