You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
{{ message }}
This repository was archived by the owner on Nov 10, 2020. It is now read-only.
Repository navigation
This repository was archived by the owner on Nov 10, 2020. It is now read-only.
In case of Client.Ping(), ackmsg.Msgbuf is empty in service.processAcked().
As a result, msg.Decode(ackmsg.Msgbuf) panics with "slice bounds out of range".
Same issue here, and the IsEOF mentioned above fixes it for me as well. I changed 2 cases in sendRecv.go and 2 more in process.go - from what I can tell, the current surgemq HEAD won't work without this workaround (this is on Mac OSX 10.11.2 with Go 1.5.3, FWIW).
here is a discussion for that error: errClosing.
and maybe oerr, ok := err.(*net.OpError)
is not necessary, just need if err.Error() == "use of closed network connection" { return true }
as @ankoh said.
Activity
ankoh commentedon Jan 6, 2016
Yep I saw that as well a while ago in your code. The problem is, that a closing socket does NOT return EOF but *net.OpError.
More information can be found here:
http://comments.gmane.org/gmane.comp.lang.go.general/76607
I decided to go for this dirty hack that was proposed in the googlegroups:
jcw commentedon Jan 20, 2016
+1
Same issue here, and the IsEOF mentioned above fixes it for me as well. I changed 2 cases in sendRecv.go and 2 more in process.go - from what I can tell, the current surgemq HEAD won't work without this workaround (this is on Mac OSX 10.11.2 with Go 1.5.3, FWIW).
zhenjl commentedon Jan 25, 2016
Thanks @jcw @ankoh ... Would either of you be willing to submit a PR?
godblesshugh commentedon Nov 7, 2016
here is a discussion for that error: errClosing.
and maybe
oerr, ok := err.(*net.OpError)is not necessary, just need
if err.Error() == "use of closed network connection" { return true }as @ankoh said.
godblesshugh commentedon Nov 7, 2016
sorry.
if err.Error() == "use of closed network connection" { return true }is not necessary, need
oerr, ok := err.(*net.OpError)lufia commentedon Apr 4, 2020
Unfortunately this repo is labeled as Unmaintained. I will reopen the issue if the status comes back to Maintained.