-
May 6th, 2013, 12:16 PM
#1
Bad Access Exception when using ls lib in background thread !!!
Hi,
I have an exception in my app, when i put the ls connection in background thread it app throw bad access exception that i can't handle it, also i can't put the calling code in workground because it takes too long to make connection with server,
Anyone has solution ?
Last edited by Vahid; May 6th, 2013 at 12:34 PM.
-
May 7th, 2013, 09:17 AM
#2
Hello,
could you be more specific? What exactly do you put in background that is causing a crash? Could you post here a code snippet? The iOS client library is designed to be thread-safe and can be used from any thread, we can surely find a solution for your problem.
Best regards,
Gianluca
-
May 18th, 2013, 07:46 AM
#3
-
May 20th, 2013, 09:51 AM
#4
Hello Vahid,
I tested your code by putting it on a sample view controller, and it worked without problems. I can't attach files here on the forums, but feel free to contact support via e-mail and I will send it to you.
What you should pay attention to, is reconnections. The library contains a lot of logic to reconnect automatically and restart existing subscriptions, even in poor network conditions. So, let the library do it for you. If you really want to reconnect manually, the correct way to do this is described at the Automatic reconnections paragraph of the Getting started with the iOS Client library page (i.e.: the first page) of the library's documentation. Take a look there.
Hope this helps.
Best regards,
Gianluca
Posting Permissions
- You may not post new threads
- You may not post replies
- You may not post attachments
- You may not edit your posts
-
Forum Rules
All times are GMT +1. The time now is 12:24 AM.
Bookmarks