Please do not post the same thing multiple times. The board software automatically flags certain posts as needing moderator attention. This happens the most often for new users. I'm pretty sure this is made clear at the time you attempt to post. Posting the same thing over and over again just makes that many more posts the moderators have to weed through later. This makes us sad. Don't make us sad. If your post/thread doesn't appear, just wait a while. Don't post it again. If it hasn't shown up by the next day, then you can try again. I normally go through posts in the mornings, and try to check a few times throughout the day, but I'm not here 24/7. There will typically be a significant delay before posts are approved. Just be patient.
When I'm debugging the app with Xcode it works like a charm and I have no crashes at all. Now when I start the app on my iphone, disconnected from Xcode, then the app crashes reproducable at serveral parts of the application (mostly with a EXC_BAD_ACCESS).
So the only way for me now to debug the app is to read the crash log and fix it this way, which is not really nice.
Do you know a possible reason/solution for this strange behavior and how I can debug again with Xcode?
Post edited by P2k on
Design Your Clock - Lets you create your custom alarm clock (+ weather)
Sounds like a pointer problem or a race condition. If it's a pointer problem then running with NSZombieEnabled or guard malloc might find it, or using clang to analyze your code.
If it's a race condition, examine any code that uses threads or "performSelectorInBackground."
Sounds like a pointer problem or a race condition. If it's a pointer problem then running with NSZombieEnabled or guard malloc might find it, or using clang to analyze your code.
If it's a race condition, examine any code that uses threads or "performSelectorInBackground."
Surprisingly, disabling NSZombie solved my problem.
The reason seems to be that NSZombie doesn't deallocate objects during runtime (see NSZombieEnabled). So the objects that caused the crashes were available and could be accessed while debugging with Xcode, but not while running the app disconnected from Xcode (because NSZombie has no influence in this case).
So essentially I have to retain these objects and my app should work again - also disconnected from my PC.
Thank You!
@scotopia I was debugging with device & with simulator. The app crashed when my device was disconnected from Xcode and/or my PC.
Design Your Clock - Lets you create your custom alarm clock (+ weather)
very helpful chap at Apple passed me this comment today, which i was not aware of, about the difference in testing using Adhoc and Debug configurations:
It's a good point about debug and Ad Hoc having differences. The most significant one of these is that Debug configurations typically don't have compiler optimizations turned on. That shouldn't matter in most cases, but there are certain types of subtle errors that manifest differently with optimized code - using an uninitialized variable for instance. In non-optimized code it might slip through without a problem, but in optimized code the value could be quite different, and cause unexpected behavior. It's developer error in either case, but easier to catch when you're doing proper testing of the Release configuration.
Replies
If it's a race condition, examine any code that uses threads or "performSelectorInBackground."
- Spam
- Abuse
- Troll
0 • Off Topic Insightful Disagree Dislike Like Awesome[IMG]http://www.omegasoftweb.com/omega/omegasoftIconBanner.png[/IMG]
Aura Trainer | <a href="http://bi
- Spam
- Abuse
- Troll
0 • Off Topic Insightful Disagree Dislike Like AwesomeThe reason seems to be that NSZombie doesn't deallocate objects during runtime (see NSZombieEnabled). So the objects that caused the crashes were available and could be accessed while debugging with Xcode, but not while running the app disconnected from Xcode (because NSZombie has no influence in this case).
So essentially I have to retain these objects and my app should work again - also disconnected from my PC.
Thank You!
@scotopia
I was debugging with device & with simulator. The app crashed when my device was disconnected from Xcode and/or my PC.
- Spam
- Abuse
- Troll
0 • Off Topic Insightful Disagree Dislike Like Awesome- Spam
- Abuse
- Troll
0 • Off Topic Insightful Disagree Dislike Like Awesome