-
Notifications
You must be signed in to change notification settings - Fork 68
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
threadedFunction() throws EXC_BAD_ACCESS #79
Comments
Checking into this right now! Can you provide any more details on your setup? It's running fine for me. Did you change what server you're connecting to? Is your internet on? Anything else of note? Let me know, we'll figure it out! |
Let me know what version of OF you're using as well |
Wow, nicest and fastest reply I've ever got on the internet! This is currently my setup: I'm connected to my WiFi, the internet is working and I didn't change the server I'm connecting to... |
Super weird! I unfortunately don't have the hardware, but it's working for me with a local nodejs server as well as a few different ones on the 'net. Hm! Can you try inspecting the "context" object where that crash is? Tried looking at libwebsockets, and it does look like some folks did have problems with the function your app is crashing on. You could try updating the underlying libwebsockets library? To confirm, does it crash on any server, or just the ESP8266? |
I tried a bunch of different servers and rolled a localhost node.js server and they worked flawlessly. The EXC_BAD_ACCESS shows only up, when I try to connect to a server in my local network, even with different WiFI-APs. At least we kinda know now what the problem is. Heh. I'm currently trying to compile the libwebsockets library to update the underlying lib as you suggested and will report asap if I stumble upon something new. |
Oh well, seems like the newest libwebsockets lib is not playing well with ofxLibwebsockets: Any idea what could fix this? If not I'm just going to get a lil' creative and write a little node.js script that sits between my ofxApp and the ESP8266. Btw.: using the directions for compiling on the readme.md I ran into some problems, mostly because Apple removed the OpenSSL header files with El Capitan. Installing the OpenSSL using the universal option and linking it properly fixes these problems easily.
Agian, thanks a lot for all the help! |
Ah geez, looking like they changed some stuff in lws, so will have to look again when it comes to bringing in the new version. Sorry! Will be a bit before I can fully update, but I may be able to push an OS X only branch in the near future. If you got it compiling, you could use their test client app (compiles along with the library) and see if it has the same problems! I'll try to see what's up with the bad access, shouldn't happen even if it can't quite see the server. Let me know if you have any more luck, sorry it's been a drag! |
Hey @dboleslawski I started seeing this problem when I added the reconnect to Use an
Or change the default value in ofxLibwebsockets/Client.cpp from @robotconscience Maybe changing the default val for reconnect to |
@mattfelsen yeah that sounds like a good idea! RE: that fixing @dboleslawski's error, see his above comment. Sounds like there's something weird going on under the hood with lws that makes it impossible :( |
Hmm, funky. The thing in the screenshot looks like a different error though – an unrecognized protocol? @dboleslawski I assume you're using this arduino/esp8266 websocket library, and your board is acting as the server? That lib defaults the protocol to "arduino" on both the server and client side...I wonder if setting the protocol to an empty string would make the lws client app stop complaining about connecting? In any case, with reconnect on I'm able to reproduce the same error if I lower the interval to something like 300ms, and turning it off makes the error disappear so hopefully it's a temp workaround for now. Tiny PR with warning note coming your way! |
Oi, I spent the last few hours trying to fix this bug, but sadly I don't really have any idea how to tackle this problem... Hopefully you can enlighten me :)
I'm trying to run the example_client_hello_world without any additions. It show the program (black window) but jumps right back to Xcode and shows this error:
![screen shot 2016-03-05 at 19 00 15](https://cloud.githubusercontent.com/assets/9035862/13549456/e15263de-e305-11e5-83aa-a5a17832a046.png)
Any ideas what could fix this? Thanks in advance!
Btw. I'm doing this on OSX 10.11.3...
The text was updated successfully, but these errors were encountered: