Closed CoderNate closed 10 months ago
oooh that's probably true. it is a fairly straightforward fix, let me get together a test thing and do a fix. in the middle of something else right now but i'll be back to it in about an hour.
neither of those commits changed the websocket though. that's weird. blocking is true by default.
Thanks for fixing this!
I'm actually not 100% sure I fixed this correctly in my code, but.... your comment and my vague recollection is that it is right now, so gonna close this. Reopen if i messed it up though.
I think https://github.com/adamdruppe/arsd/commit/0d61b0ef04813d62fe2adadbb93c8cbee2f85d35 and/or the commit before it from the same day (https://github.com/adamdruppe/arsd/commit/50592d35f34ac452ce182668dc3f4b07c32913ff) caused the problem I'm seeing where connecting to a wss address fails. The changes modified
connect
so thatdo_ssl_connect
would only be called if blocking is true. TheWebSocket
class creates and uses its own privateSslClientSocket
and the socket seems to default to blocking being false. Here's my code:In arsd 10.9.6 I ran through with a debugger and verified that connect skips over the
do_ssl_connect
call. But if I edit the code and addsocket.blocking = true
at the end of theWebsocket
constructor then the call toconnect
works and I can then send and receive messages.I verified that arsd 10.8.4 (the last tagged release before the commit I linked) was able to connect over wss and send and receive a message.