0

I have a problem when i press physically button on my keyboard. Drubber breaks on:

@UIApplicationMain
class AppDelegate: UIResponder, UIApplicationDelegate { // <- breaks here

    var window: UIWindow?
...
}

And in log i can see only this =(

    2016-02-13 22:16:37.147 RB[2780:107547] -[NSNull _fastCStringContents:]: unrecognized selector sent to instance 0x102e63af0
    2016-02-13 22:16:37.149 RB[2780:107547] *** Terminating app due to uncaught exception 'NSInvalidArgumentException', reason: '-[NSNull _fastCStringContents:]: unrecognized selector sent to instance 0x102e63af0'
    *** First throw call stack:
    (
        0   CoreFoundation                      0x0000000102c3ee65 __exceptionPreprocess + 165
        1   libobjc.A.dylib                     0x000000010497edeb objc_exception_throw + 48
        2   CoreFoundation                      0x0000000102c4748d -[NSObject(NSObject) doesNotRecognizeSelector:] + 205
        3   CoreFoundation                      0x0000000102b9490a ___forwarding___ + 970
        4   CoreFoundation                      0x0000000102b944b8 _CF_forwarding_prep_0 + 120
        5   CoreFoundation                      0x0000000102c2af23 -[NSTaggedPointerString compare:options:range:locale:] + 243
        6   Foundation                          0x0000000102fd1e37 -[NSString compare:options:range:] + 29
        7   UIKit                               0x0000000103745e6f -[UIPhysicalKeyboardEvent _matchesKeyCommand:] + 303
        8   UIKit                               0x000000010366a3fd -[UIResponder _keyCommandForEvent:target:] + 364
        9   UIKit                               0x000000010366a5b2 -[UIResponder _keyCommandForEvent:target:] + 801
        10  UIKit                               0x000000010347c1aa -[UIApplication handleKeyHIDEvent:] + 397
        11  UIKit                               0x0000000103455838 _UIApplicationHandleEventQueue + 5469
        12  CoreFoundation                      0x0000000102b6aa31 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 17
        13  CoreFoundation                      0x0000000102b6095c __CFRunLoopDoSources0 + 556
        14  CoreFoundation                      0x0000000102b5fe13 __CFRunLoopRun + 867
        15  CoreFoundation                      0x0000000102b5f828 CFRunLoopRunSpecific + 488
        16  GraphicsServices                    0x0000000106d18ad2 GSEventRunModal + 161
        17  UIKit                               0x000000010345b610 UIApplicationMain + 171
        18  RB                                  0x00000001021524cd main + 109
        19  libdyld.dylib                       0x000000010549092d start + 1
    )
    libc++abi.dylib: terminating with uncaught exception of type NSException

Anyone have the answer ?

  • More context is needed. The error comes from NSNull and strings, but none of these appear in your code sample. – jtbandes Feb 13 '16 at 19:39
  • Take a moment to read this, http://www.raywenderlich.com/10209/my-app-crashed-now-what-part-1 – Ulysses Feb 13 '16 at 19:42
  • Those crashes in the app delegate usually are things whith wrong reference, double check the storyboard connections to the classes, and put an Exception Breakpoints to see where it really crashes – Ulysses Feb 13 '16 at 19:43
  • Try to find an answer here: http://stackoverflow.com/questions/7522766/what-is-nsurl-fastcharactercontents – Lirik Feb 13 '16 at 19:58
  • Exception breakpoints stuck right on class "AppDelegate:" - this is fully generated by Xcode file. I newer touch this. My problem happens only when i run my app on emulator and press button from keyboard. Emulator window must be active. If it in bg bug not happens. Simply i can't suspend app when press cmd + H. – Pavel Kopkov Feb 19 '16 at 18:23

0 Answers0