2011-03-24 81 views
1

我的MonoTouch應用程序(發佈版本)隨機崩潰,我在崩潰日誌中找到它。不幸的是,我沒有看到與我的應用有關的任何有用信息。它看起來像是在MonoTouch和iOS的深處。有助於理解MonoTouch崩潰日誌

我正在使用OS 3.1.2的iPhone 3G上運行此操作。

任何人都可以幫助我理解這個崩潰日誌的含義嗎?


Incident Identifier: 222781AB-0F7C-4E1D-9E10-6EE946D6C320 
CrashReporter Key: 0ee985a48f32f63b7e50536870f06a1ab4122600 
Process:   MyApp_iOS [593] 
Path:   /var/mobile/Applications/095A615B-2F9B-4A84-B0E3-EF1246915594/MyApp_iOS.app/MyApp_iOS 
Identifier:  MyApp_iOS 
Version:   ??? (???) 
Code Type:  ARM (Native) 
Parent Process: launchd [1] 

Date/Time:  2011-03-24 13:04:18.479 -0700 
OS Version:  iPhone OS 3.1.2 (7D11) 
Report Version: 104 

Exception Type: EXC_CRASH (SIGABRT) 
Exception Codes: 0x00000000, 0x00000000 
Crashed Thread: 0 

Thread 0 Crashed: 
0 dyld        0x2fe125b2 ImageLoaderMachOCompressed::findExportedSymbol(char const*, ImageLoader const**) const + 58 
1 dyld        0x2fe0dcd6 ImageLoaderMachO::findExportedSymbol(char const*, bool, ImageLoader const**) const + 30 
2 dyld        0x2fe0ee6e ImageLoaderMachOClassic::resolveUndefined(ImageLoader::LinkContext const&, macho_nlist const*, bool, bool, ImageLoader const**) + 434 
3 dyld        0x2fe10250 ImageLoaderMachOClassic::doBindLazySymbol(unsigned long*, ImageLoader::LinkContext const&) + 212 
4 dyld        0x2fe037ae dyld::bindLazySymbol(mach_header const*, unsigned long*) + 94 
5 dyld        0x2fe0e29c stub_binding_helper_interface + 12 
6 MyApp_iOS       0x0071a754 mono_handle_native_sigsegv (mini-exceptions.c:1762) 
7 MyApp_iOS       0x0073d900 sigabrt_signal_handler (mini-posix.c:155) 
8 libSystem.B.dylib     0x0008e81c _sigtramp + 28 
9 libSystem.B.dylib     0x00033904 semaphore_wait_signal + 4 
10 libSystem.B.dylib     0x00003ca8 pthread_mutex_lock + 440 
11 MyApp_iOS       0x0088e76c GC_lock (pthread_support.c:1679) 
12 MyApp_iOS       0x00884970 GC_malloc_atomic (malloc.c:259) 
13 MyApp_iOS       0x007f26e4 mono_object_new_ptrfree_box (object.c:3996) 


[... there are 10 active threads but I've only included the one that crashed] 


Thread 0 crashed with ARM Thread State: 
    r0: 0x00000000 r1: 0x0097dc97  r2: 0x344d7c3c  r3: 0x344dd2bd 
    r4: 0x344dd2bd r5: 0x00005681  r6: 0x0097dc97  r7: 0x2fffe6d8 
    r8: 0x344e7f34 r9: 0x00000001  r10: 0x0000007f  r11: 0x0097dc97 
    ip: 0x344d8e4c sp: 0x2fffe658  lr: 0x2fe0dcdd  pc: 0x2fe125b2 
    cpsr: 0x20000030 
+0

最好有一個可重複的測試用例,堆棧跟蹤不會提供很多提示 – 2011-03-25 17:23:39

回答

5

另一個診斷選項,我發現是:

  1. 胡克AppDomain.CurrentDomain.UnhandledException
  2. 將在你的整個「靜態無效的主要一個try-catch() 「方法

在這兩個原因中都寫入Console.WriteLine()的異常。

然後運行您的應用程序,打開XCode並在設備插入時打開設備的控制檯窗口,然後導致崩潰。你應該能夠看到一個像樣的C#棧跟蹤異常。

這幫助我解決了許多問題,只有在設備上運行時纔會發生。

+0

謝謝,這是一個很棒的提示! – Mike 2011-03-29 17:38:45