I am running iOS7 on an iPhone 4S and my app runs fine until I power down my iPhone and power it back on. When I launch my app it simply just flashes a black screen and then takes the user back to the iPhone app icon view. Also, my app uses RestKit .20.3 and ZBar for bar code scanning and is built using Xcode 5 on Mountain Lion. Then I connect my iPhone back to Xcode and then rerun the app and everything is fine again. Has anyone else experienced this issue. Below is a snippet from my crash log;
Date/Time: 2013-10-03 22:23:41.334 -0400
OS Version: iOS 7.0.2 (11A501)
Report Version: 104
Exception Type: EXC_BREAKPOINT (SIGTRAP)
Exception Codes: 0x0000000000000001, 0x00000000e7ffdefe
Triggered by Thread: 0
Dyld Error Message:
Library not loaded: /Developer/Library/Frameworks/SenTestingKit.framework/SenTestingKit
Referenced from: /var/mobile/Applications/DC06399E-15F3-46B1-B194-24CC93B763E2/ Genie.app/Genie
Reason: image not found
Dyld Version: 324
Binary Images:
0x2be76000 - 0x2be96fff dyld armv7 <b37cba000c7d3f8ea414f060d45ce144> /usr/lib/dyld
0x30e47000 - 0x30f4cfff CFNetwork armv7 <0ad158ad8b7a3716ad04ffde6081754c> /System/Library/Frameworks/CFNetwork.framework/CFNetwork
0x30fbf000 - 0x311affff CoreData armv7 <9338ccb7c0f2377196e181eb10b15ef5> /System/Library/Frameworks/CoreData.framework/CoreData
0x312f3000 - 0x31416fff CoreGraphics armv7 <17a70d032a013c06b9a4d244b100e2b3> /System/Library/Frameworks/CoreGraphics.framework/CoreGraphics
0x31b99000 - 0x31d83fff Foundation armv7 <75c827267c5a3c85a3b21a9459d3c312> /System/Library/Frameworks/Foundation.framework/Foundation
0x329f5000 - 0x32a58fff MobileCoreServices armv7 <5d5b5ca6dd7a305688d5a4d47363d534> /System/Library/Frameworks/MobileCoreServices.framework/MobileCoreServices
0x3380f000 - 0x3384ffff Security armv7 <492fcd48d4de3f29b01799ace718d3d7> /System/Library/Frameworks/Security.framework/Security
Was able to solve my issue by making SenTestingKit "optional" under the linked libraries in my Target, Build Phases. Also, used some of the tips in this posting stackoverflow.com/questions/7895296/… but, due to your original comment I was able to piece this together. Thanks again for your useful comments.
Test support pods like
- Specta
- OCMock
- OCHamcrest
- Expecta
don't belong in your main target (assuming you don't use OCHamcrest matchers for non-test purposes). They need to be targeted exclusively to your test target, something like this:
target :MyTests, :exclusive => true do
pod 'Specta', '0.1.8'
…etc…
end
来源:https://stackoverflow.com/questions/19172359/app-crashes-after-power-down-on-iphone-4s