The problem I'm having is that in my brand new project I have a Window with a button (Outlet and Action defined) and in my C# code I've wired up the partial void implementation of the Action. Then I have a View that I load and do the same thing.
The issue is that the View causes a System.NullReferenceException, the 'Click' code never gets run, instead I end up with the following full trace
Loaded assembly: /Developer/MonoTouch/usr/lib/mono/2.1/monotouch.dll [External]
Loaded assembly: /Developer/MonoTouch/usr/lib/mono/2.1/System.Core.dll [External]
Loaded assembly: /Users/drisszouak/Projects/ZenVelopes/ZenVelopes/bin/iPhoneSimulator/Debug/ZenVelopes.exe
Stacktrace:
at (wrapper managed-to-native) MonoTouch.UIKit.UIApplication.UIApplicationMain (int,string[],intptr,intptr) <0x00004>
at (wrapper managed-to-native) MonoTouch.UIKit.UIApplication.UIApplicationMain (int,string[],intptr,intptr) <0x00004>
at MonoTouch.UIKit.UIApplication.Main (string[],string,string) [0x00038] in /Users/plasma/Source/iphone/monotouch/UIKit/UIApplication.cs:26
at MonoTouch.UIKit.UIApplication.Main (string[]) [0x00000] in /Users/plasma/Source/iphone/monotouch/UIKit/UIApplication.cs:31
at ZenVelopes.Application.Main (string[]) [0x00000] in /Users/drisszouak/Projects/ZenVelopes/ZenVelopes/Main.cs:14
at (wrapper runtime-invoke) <Module>.runtime_invoke_void_object (object,intptr,intptr,intptr) <IL 0x0001d, 0x00090>
Native stacktrace:
0 ZenVelopes 0x000be66f mono_handle_native_sigsegv + 343
1 ZenVelopes 0x0000e43e mono_sigsegv_signal_handler + 313
2 libSystem.B.dylib 0x9118246b _sigtramp + 43
3 ??? 0xffffffff 0x0 + 4294967295
4 UIKit 0x01def167 -[UIBarButtonItem(UIInternal) _sendAction:withEvent:] + 156
5 UIKit 0x01be1a6e -[UIApplication sendAction:to:from:forEvent:] + 119
6 UIKit 0x01c701b5 -[UIControl sendAction:to:forEvent:] + 67
7 UIKit 0x01c72647 -[UIControl(Internal) _sendActionsForEvents:withEvent:] + 527
8 UIKit 0x01c711f4 -[UIControl touchesEnded:withEvent:] + 458
9 UIKit 0x01c060d1 -[UIWindow _sendTouchesForEvent:] + 567
10 UIKit 0x01be737a -[UIApplication sendEvent:] + 447
11 UIKit 0x01bec732 _UIApplicationHandleEvent + 7576
12 GraphicsServices 0x03eb7a36 PurpleEventCallback + 1550
13 CoreFoundation 0x00df9064 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 52
14 CoreFoundation 0x00d596f7 __CFRunLoopDoSource1 + 215
15 CoreFoundation 0x00d56983 __CFRunLoopRun + 979
16 CoreFoundation 0x00d56240 CFRunLoopRunSpecific + 208
17 CoreFoundation 0x00d56161 CFRunLoopRunInMode + 97
18 GraphicsServices 0x03eb6268 GSEventRunModal + 217
19 GraphicsServices 0x03eb632d GSEventRun + 115
20 UIKit 0x01bf042e UIApplicationMain + 1160
21 ??? 0x09e39862 0x0 + 165910626
22 ??? 0x09e39632 0x0 + 165910066
23 ??? 0x09e38c9a 0x0 + 165907610
24 ??? 0x09e38aec 0x0 + 165907180
25 ??? 0x09e38ba1 0x0 + 165907361
26 ZenVelopes 0x0000e202 mono_jit_runtime_invoke + 1360
27 ZenVelopes 0x001c92af mono_runtime_invoke + 137
28 ZenVelopes 0x001caf6b mono_runtime_exec_main + 714
29 ZenVelopes 0x001ca891 mono_runtime_run_main + 812
30 ZenVelopes 0x00094fe8 mono_jit_exec + 200
31 ZenVelopes 0x0027cf05 main + 3494
32 ZenVelopes 0x00002ca1 _start + 208
33 ZenVelopes 0x00002bd0 start + 40
34 ??? 0x00000002 0x0 + 2
Debug info from gdb:
warning: Could not find object file "/var/folders/Ny/NyElTwhDGD8kZMqIEeLGXE+++TI/-Tmp-//cc6F1tBs.o" - no debug information available for "template.m".
warning: .o file "/Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator4.2.sdk/usr/lib/libmonotouch.a(zlib-helper.x86.42.o)" more recent than executable timestamp in "/Users/drisszouak/Library/Application Support/iPhone Simulator/4.2/Applications/9B8EA00C-09B4-4D08-ABF7-7CF4487F1A28/ZenVelopes.app/ZenVelopes"
warning: Could not open OSO file /Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator4.2.sdk/usr/lib/libmonotouch.a(zlib-helper.x86.42.o) to scan for pubtypes for objfile /Users/drisszouak/Library/Application Support/iPhone Simulator/4.2/Applications/9B8EA00C-09B4-4D08-ABF7-7CF4487F1A28/ZenVelopes.app/ZenVelopes
warning: .o file "/Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator4.2.sdk/usr/lib/libmonotouch.a(monotouch-glue.x86.42.o)" more recent than executable timestamp in "/Users/drisszouak/Library/Application Support/iPhone Simulator/4.2/Applications/9B8EA00C-09B4-4D08-ABF7-7CF4487F1A28/ZenVelopes.app/ZenVelopes"
warning: Could not open OSO file /Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator4.2.sdk/usr/lib/libmonotouch.a(monotouch-glue.x86.42.o) to scan for pubtypes for objfile /Users/drisszouak/Library/Application Support/iPhone Simulator/4.2/Applications/9B8EA00C-09B4-4D08-ABF7-7CF4487F1A28/ZenVelopes.app/ZenVelopes
warning: .o file "/Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator4.2.sdk/usr/lib/libmonotouch.a(gc.x86.42.o)" more recent than executable timestamp in "/Users/drisszouak/Library/Application Support/iPhone Simulator/4.2/Applications/9B8EA00C-09B4-4D08-ABF7-7CF4487F1A28/ZenVelopes.app/ZenVelopes"
warning: Could not open OSO file /Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator4.2.sdk/usr/lib/libmonotouch.a(gc.x86.42.o) to scan for pubtypes for objfile /Users/drisszouak/Library/Application Support/iPhone Simulator/4.2/Applications/9B8EA00C-09B4-4D08-ABF7-7CF4487F1A28/ZenVelopes.app/ZenVelopes
warning: .o file "/Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator4.2.sdk/usr/lib/libmonotouch.a(monotouch-glue.x86.42.o)" more recent than executable timestamp in "/Users/drisszouak/Library/Application Support/iPhone Simulator/4.2/Applications/9B8EA00C-09B4-4D08-ABF7-7CF4487F1A28/ZenVelopes.app/ZenVelopes"
warning: Couldn't open object file '/Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator4.2.sdk/usr/lib/libmonotouch.a(monotouch-glue.x86.42.o)'
Attaching to process 10857.
Reading symbols for shared libraries . done
Reading symbols for shared libraries ...................................................................................................................... done
0x91127459 in read$UNIX2003 ()
7 "WebThread" 0x9111c0fa in mach_msg_trap ()
6 0x9114a0a6 in __semwait_signal ()
5 0x911595fe in recvfrom$UNIX2003 ()
4 0x9111c136 in semaphore_wait_trap ()
3 0x9111c0fa in mach_msg_trap ()
2 "com.apple.libdispatch-manager" 0x91142982 in kevent ()
* 1 "com.apple.main-thread" 0x91127459 in read$UNIX2003 ()
Thread 7 (process 10857):
#0 0x9111c0fa in mach_msg_trap ()
#1 0x9111c867 in mach_msg ()
#2 0x00df94a6 in __CFRunLoopServiceMachPort ()
#3 0x00d56874 in __CFRunLoopRun ()
#4 0x00d56240 in CFRunLoopRunSpecific ()
#5 0x00d56161 in CFRunLoopRunInMode ()
#6 0x04f7c423 in RunWebThread ()
#7 0x9114985d in _pthread_start ()
#8 0x911496e2 in thread_start ()
Thread 6 (process 10857):
#0 0x9114a0a6 in __semwait_signal ()
#1 0x91175ee5 in nanosleep$UNIX2003 ()
#2 0x91175e23 in usleep$UNIX2003 ()
#3 0x0027714c in monotouch_pump_gc ()
#4 0x9114985d in _pthread_start ()
#5 0x911496e2 in thread_start ()
Thread 5 (process 10857):
#0 0x911595fe in recvfrom$UNIX2003 ()
#1 0x911793c7 in recv$UNIX2003 ()
#2 0x000d8cca in recv_length (fd=6, buf=0xb0388ebd, len=11, flags=0) at ../../../../mono/mini/debugger-agent.c:939
#3 0x000e616a in debugger_thread (arg=0x0) at ../../../../mono/mini/debugger-agent.c:6290
#4 0x002448e2 in thread_start_routine (args=0x80339a8) at ../../../../mono/io-layer/wthreads.c:286
#5 0x00274357 in GC_start_routine (arg=0x6ff6f60) at ../../../libgc/pthread_support.c:1390
#6 0x9114985d in _pthread_start ()
#7 0x911496e2 in thread_start ()
Thread 4 (process 10857):
#0 0x9111c136 in semaphore_wait_trap ()
#1 0x0015ae1d in finalizer_thread (unused=0x0) at ../../../../mono/metadata/gc.c:1026
#2 0x002034a3 in start_wrapper (data=0x7b18620) at ../../../../mono/metadata/threads.c:661
#3 0x002448e2 in thread_start_routine (args=0x80338b0) at ../../../../mono/io-layer/wthreads.c:286
#4 0x00274357 in GC_start_routine (arg=0x6ff6f60) at ../../../libgc/pthread_support.c:1390
#5 0x9114985d in _pthread_start ()
#6 0x911496e2 in thread_start ()
Thread 3 (process 10857):
#0 0x9111c0fa in mach_msg_trap ()
#1 0x9111c867 in mach_msg ()
#2 0x0011cc46 in mach_exception_thread (arg=0x0) at ../../../../mono/mini/mini-darwin.c:138
#3 0x9114985d in _pthread_start ()
#4 0x911496e2 in thread_start ()
Thread 2 (process 10857):
#0 0x91142982 in kevent ()
#1 0x9114309c in _dispatch_mgr_invoke ()
#2 0x91142559 in _dispatch_queue_invoke ()
#3 0x911422fe in _dispatch_worker_thread2 ()
#4 0x91141d81 in _pthread_wqthread ()
#5 0x91141bc6 in start_wqthread ()
Thread 1 (process 10857):
#0 0x91127459 in read$UNIX2003 ()
#1 0x000be81f in mono_handle_native_sigsegv (signal=11, ctx=0xbfffd228) at ../../../../mono/mini/mini-exceptions.c:1826
#2 0x0000e43e in mono_sigsegv_signal_handler (_dummy=10, info=0xbfffd1e8, context=0xbfffd228) at ../../../../mono/mini/mini.c:4846
#3 <signal handler called>
#4 0x028d6a63 in objc_msgSend ()
#5 0x07b96550 in ?? ()
#6 0x01def167 in -[UIBarButtonItem(UIInternal) _sendAction:withEvent:] ()
#7 0x01be1a6e in -[UIApplication sendAction:to:from:forEvent:] ()
#8 0x01c701b5 in -[UIControl sendAction:to:forEvent:] ()
#9 0x01c72647 in -[UIControl(Internal) _sendActionsForEvents:withEvent:] ()
#10 0x01c711f4 in -[UIControl touchesEnded:withEvent:] ()
#11 0x01c060d1 in -[UIWindow _sendTouchesForEvent:] ()
#12 0x01be737a in -[UIApplication sendEvent:] ()
#13 0x01bec732 in _UIApplicationHandleEvent ()
#14 0x03eb7a36 in PurpleEventCallback ()
#15 0x00df9064 in __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ ()
#16 0x00d596f7 in __CFRunLoopDoSource1 ()
#17 0x00d56983 in __CFRunLoopRun ()
#18 0x00d56240 in CFRunLoopRunSpecific ()
#19 0x00d56161 in CFRunLoopRunInMode ()
#20 0x03eb6268 in GSEventRunModal ()
#21 0x03eb632d in GSEventRun ()
#22 0x01bf042e in UIApplicationMain ()
#23 0x09e39862 in ?? ()
#24 0x09e39632 in ?? ()
#25 0x09e38c9a in ?? ()
#26 0x09e38aec in ?? ()
#27 0x09e38ba1 in ?? ()
#28 0x0000e202 in mono_jit_runtime_invoke (method=0x8119afc, obj=0x0, params=0xbfffed9c, exc=0x0) at ../../../../mono/mini/mini.c:4733
#29 0x001c92af in mono_runtime_invoke (method=0x8119afc, obj=0x0, params=0xbfffed9c, exc=0x0) at ../../../../mono/metadata/object.c:2615
#30 0x001caf6b in mono_runtime_exec_main (method=0x8119afc, args=0x9e0d1a0, exc=0x0) at ../../../../mono/metadata/object.c:3581
#31 0x001ca891 in mono_runtime_run_main (method=0x8119afc, argc=0, argv=0xbfffeed4, exc=0x0) at ../../../../mono/metadata/object.c:3355
#32 0x00094fe8 in mono_jit_exec (domain=0x6f91e58, assembly=0x7b8ca10, argc=1, argv=0xbfffeed0) at ../../../../mono/mini/driver.c:1094
#33 0x0027cf05 in main ()
=================================================================
Got a SIGSEGV while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries
used by your application.
=================================================================
On the advice of a friend, I uninstalled Mono, MonoTouch, MonoDevelop and the iOS SDK and then redownloaded them, reinstalled them in iOS SDK, Mono, MT (Personal licensed edition), MD order. This didn't change a thing.
The line #14 that is referenced in my Main is this one:
public class Application
{
static void Main (string[] args)
{
#14 ====> UIApplication.Main (args);
}
}
The Partial void 'click' event that I'm wiring up is this (solely for testing purposes). The code never arrives here, the exception blows up before it.
partial void clickNewEnvelope (UIBarButtonItem sender)
{
int x;
x = 1;
}
When I create a new project, I'm getting the same thing.
I am seriously stumped, help.
It looks like you're dangling an event off a UIBarButtonItem and not keeping a reference to it. Any time you do
foo.SomeEvent += delegate {};
You need to keep a reference to "foo" so that the hidden class which implements the protocol isn't collected, as the UIBarButtonItem in this case is the owner of that hidden class.
Related
I have a class derived from UIControl called MyObject and I also have a List that holds several objects on MyObject type.
All these objects are added as SubViews in ViewDidLoad overridden method of UIViewController before calling base.ViewDidLoad (); (I don't know if this is important).
The thing is that at certain periods I want to remove several objects because I don't need them anymore. Here is what steps I take:
- First of all I remove that object from my generic list collection
- Then I remove it from view using RemoveFromSuperview() method.
At this point everything works well, but I also want to get rid of it from memory because I don't need it anymore and I also need to add some more objects so I have to free some memory. So I call Dispose() method on that object.
As soon as I do it I get a nasty exception:
Stacktrace:
at (wrapper managed-to-native) MonoTouch.ObjCRuntime.Messaging.void_objc_msgSendSuper_RectangleF (intptr,intptr,System.Drawing.RectangleF) <IL 0x00025, 0xffffffff>
at MonoTouch.UIKit.UIView.set_Frame (System.Drawing.RectangleF) [0x00021] in /Developer/MonoTouch/Source/monotouch/src/UIKit/UIView.g.cs:1179
at BubbleBuster.Lib.UI.Gameplay.Bubble.Update (System.Drawing.RectangleF) [0x001a2] in /Development/Helix/iOS/BubbleBuster/BubbleBusterSolution/BubbleBusterApp/Lib/UI/Gameplay/Bubble.cs:141
at BubbleBuster.Lib.UI.Gameplay.BubbleCollection/<Update>c__AnonStorey2.<>m__4 (BubbleBuster.Lib.UI.Gameplay.Bubble) [0x00014] in /Development/Helix/iOS/BubbleBuster/BubbleBusterSolution/BubbleBusterApp/Lib/UI/Gameplay/BubbleCollection.cs:21
at System.Collections.Generic.List`1.ForEach (System.Action`1<T>) [0x00018] in /Developer/MonoTouch/Source/mono/mcs/class/corlib/System.Collections.Generic/List.cs:360
at BubbleBuster.Lib.UI.Gameplay.BubbleCollection.Update (System.Drawing.RectangleF) [0x00014] in /Development/Helix/iOS/BubbleBuster/BubbleBusterSolution/BubbleBusterApp/Lib/UI/Gameplay/BubbleCollection.cs:19
at BubbleBuster.Lib.UI.Screens.WelcomeScreen.<UpdateTime_Elapsed>m__1 () [0x00000] in /Development/Helix/iOS/BubbleBuster/BubbleBusterSolution/BubbleBusterApp/Lib/UI/Screens/WelcomeScreen.cs:44
at MonoTouch.Foundation.NSActionDispatcher.Apply () [0x00000] in /Developer/MonoTouch/Source/monotouch/src/shared/Foundation/NSAction.cs:48
at (wrapper runtime-invoke) object.runtime_invoke_void__this__ (object,intptr,intptr,intptr) <IL 0x0004e, 0xffffffff>
at (wrapper managed-to-native) MonoTouch.UIKit.UIApplication.UIApplicationMain (int,string[],intptr,intptr) <IL 0x0009f, 0xffffffff>
Thread started:
at MonoTouch.UIKit.UIApplication.Main (string[],string,string) [0x00042] in /Developer/MonoTouch/Source/monotouch/src/UIKit/UIApplication.cs:29
at BubbleBuster.Application.Main (string[]) [0x00000] in /Development/Helix/iOS/BubbleBuster/BubbleBusterSolution/BubbleBusterApp/Main.cs:17
at (wrapper runtime-invoke) <Module>.runtime_invoke_void_object (object,intptr,intptr,intptr) <IL 0x00050, 0xffffffff>
Native stacktrace:
0 BubbleBusterApp 0x0009094c mono_handle_native_sigsegv + 284
1 BubbleBusterApp 0x00005cd8 mono_sigsegv_signal_handler + 248
2 libsystem_c.dylib 0x9923959b _sigtramp + 43
3 ??? 0xffffffff 0x0 + 4294967295
4 ??? 0x0e2662b8 0x0 + 237396664
5 ??? 0x0e2661dc 0x0 + 237396444
6 ??? 0x0e2651c6 0x0 + 237392326
7 ??? 0x0e269920 0x0 + 237410592
8 ??? 0x0e24f8e2 0x0 + 237304034
9 ??? 0x0e2697e4 0x0 + 237410276
10 ??? 0x0e269678 0x0 + 237409912
11 ??? 0x0e2695e0 0x0 + 237409760
12 ??? 0x09fe9a90 0x0 + 167680656
13 BubbleBusterApp 0x0000a042 mono_jit_runtime_invoke + 722
14 BubbleBusterApp 0x00169f4e mono_runtime_invoke + 126
15 BubbleBusterApp 0x00206748 monotouch_trampoline + 3416
16 CoreFoundation 0x011d6e42 -[NSObject performSelector:withObject:] + 66
17 Foundation 0x017509df __NSThreadPerformPerform + 254
18 CoreFoundation 0x011a994f __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 15
19 CoreFoundation 0x0110cb43 __CFRunLoopDoSources0 + 243
20 CoreFoundation 0x0110c424 __CFRunLoopRun + 1012
21 CoreFoundation 0x0110bd84 CFRunLoopRunSpecific + 212
22 CoreFoundation 0x0110bc9b CFRunLoopRunInMode + 123
23 GraphicsServices 0x047c47d8 GSEventRunModal + 190
24 GraphicsServices 0x047c488a GSEventRun + 103
25 UIKit 0x02258626 UIApplicationMain + 1163
26 ??? 0x0d7c4a05 0x0 + 226249221
27 ??? 0x0d53cf18 0x0 + 223596312
28 ??? 0x0d53cc10 0x0 + 223595536
29 ??? 0x0d53cd66 0x0 + 223595878
30 BubbleBusterApp 0x0000a042 mono_jit_runtime_invoke + 722
31 BubbleBusterApp 0x00169f4e mono_runtime_invoke + 126
32 BubbleBusterApp 0x0016e034 mono_runtime_exec_main + 420
33 BubbleBusterApp 0x00173455 mono_runtime_run_main + 725
34 BubbleBusterApp 0x00067245 mono_jit_exec + 149
35 BubbleBusterApp 0x002116a5 main + 2837
36 BubbleBusterApp 0x00003095 start + 53
=================================================================
Got a SIGSEGV while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries
used by your application.
=================================================================
From here:
at MonoTouch.UIKit.UIView.set_Frame (System.Drawing.RectangleF) [0x00021] in /Developer/MonoTouch/Source/monotouch/src/UIKit/UIView.g.cs:1179
it looks like you're setting Frame on a view that has already been freed.
When you create the view, set it's tag to 333 i.e.
To dispose the view:
MyCreatedView.ViewWithTag(333).RemoveFromSuperview();
Where -MyCreatedView- is the parent view of the view you want to get rid of.
I am trying to play an mp3 file with the following code.
AVAudioPlayer player = new AVAudioPlayer();
NSUrl mediaFile = NSUrl.FromFilename(monkeySound);
player = AVAudioPlayer.FromUrl(mediaFile);
player.Delegate = new PlayerDelegate();
if(player.PrepareToPlay()){
player.Play();
}
private class PlayerDelegate:AVAudioPlayerDelegate {
public PlayerDelegate(){
}
public override void FinishedPlaying (AVAudioPlayer player, bool flag)
{
//Some Stuff Done Here
}
}
This is the error I get:
Stacktrace:
at (wrapper managed-to-native) MonoTouch.ObjCRuntime.Messaging.void_objc_msgSend (intptr,intptr)
at MonoTouch.Foundation.NSObject/MonoTouch_Disposer.Drain (MonoTouch.Foundation.NSObject) [0x0002a] in /Users/plasma/Source/iphone/monotouch/Foundation/NSObject.cs:305
at (wrapper runtime-invoke) .runtime_invoke_void_this__object (object,intptr,intptr,intptr)
at (wrapper managed-to-native) MonoTouch.UIKit.UIApplication.UIApplicationMain (int,string[],intptr,intptr)
at MonoTouch.UIKit.UIApplication.Main (string[],string,string) [0x00038] in /Users/plasma/Source/iphone/monotouch/UIKit/UIApplication.cs:26
at MonoTouch.UIKit.UIApplication.Main (string[]) [0x00000] in /Users/plasma/Source/iphone/monotouch/UIKit/UIApplication.cs:31
at MonkeyShot.Application.Main (string[]) [0x00000] in /Users/fencer04/Projects/MonkeyShot/MonkeyShot/Main.cs:14
at (wrapper runtime-invoke) .runtime_invoke_void_object (object,intptr,intptr,intptr)
Native stacktrace:
0 MonkeyShot 0x000d0d25 mono_handle_native_sigsegv + 343
1 MonkeyShot 0x0000f6f4 mono_sigsegv_signal_handler + 322
2 libSystem.B.dylib 0x992a345b _sigtramp + 43
3 ??? 0xffffffff 0x0 + 4294967295
4 AVFoundation 0x0047c28d -[AVAudioPlayer privCommonCleanup] + 50
5 AVFoundation 0x0047c339 -[AVAudioPlayer dealloc] + 51
6 ??? 0x0a2af91c 0x0 + 170588444
7 ??? 0x0a2cab1c 0x0 + 170699548
8 ??? 0x077520d6 0x0 + 125116630
9 MonkeyShot 0x0000f4af mono_jit_runtime_invoke + 1332
10 MonkeyShot 0x001ed319 mono_runtime_invoke + 137
11 MonkeyShot 0x0029da57 monotouch_trampoline + 2527
12 Foundation 0x0140d94e __NSThreadPerformPerform + 251
13 CoreFoundation 0x00e9f8ff __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE0_PERFORM_FUNCTION__ + 15
14 CoreFoundation 0x00dfd88b __CFRunLoopDoSources0 + 571
15 CoreFoundation 0x00dfcd86 __CFRunLoopRun + 470
16 CoreFoundation 0x00dfc840 CFRunLoopRunSpecific + 208
17 CoreFoundation 0x00dfc761 CFRunLoopRunInMode + 97
18 GraphicsServices 0x0404b1c4 GSEventRunModal + 217
19 GraphicsServices 0x0404b289 GSEventRun + 115
20 UIKit 0x01cdfc93 UIApplicationMain + 1160
21 ??? 0x09d530a3 0x0 + 164966563
22 ??? 0x09d52e74 0x0 + 164966004
23 ??? 0x09d52474 0x0 + 164963444
24 ??? 0x09d522cc 0x0 + 164963020
25 ??? 0x09d5241e 0x0 + 164963358
26 MonkeyShot 0x0000f4af mono_jit_runtime_invoke + 1332
27 MonkeyShot 0x001ed319 mono_runtime_invoke + 137
28 MonkeyShot 0x001efa00 mono_runtime_exec_main + 669
29 MonkeyShot 0x001eedea mono_runtime_run_main + 843
30 MonkeyShot 0x000a3083 mono_jit_exec + 200
31 MonkeyShot 0x002a1697 main + 3838
32 MonkeyShot 0x00002809 _start + 208
33 MonkeyShot 0x00002738 start + 40
Debug info from gdb:
/tmp/mono-gdb-commands.0GDVJY:1: Error in sourced command file:
unable to debug self
===============================================================
Got a SIGSEGV while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries
used by your application.
I don't know if this is your issue, but I had some issues using the C#-style delegate methods and AVAudioPlayer. If this is similar to my issue, using the "WeakDelegate" construct and exporting methods might be useful.
I just upgraded Monotouch to latest 4.0 and MonoFramework to 2.10.1_3.macos10 and now none of my existing projects run on simulator. If I create a new project, it runs fine. How can I fix this?
If I click on the Run button in Monodevelop, the build completes successfully, but at the Application Output window I get this error:
Error connecting stdout and stderr (127.0.0.1:10001)
Couldn't register com.yourcompany.textproblem with the bootstrap server. Error: unknown error code.
This generally means that another instance of this process was already running or is hung in the debugger.Stacktrace:
at (wrapper managed-to-native) MonoTouch.UIKit.UIApplication.UIApplicationMain (int,string[],intptr,intptr) <IL 0x0009f, 0xffffffff>
at MonoTouch.UIKit.UIApplication.Main (string[],string,string) [0x00038] in /Users/plasma/Source/iphone/monotouch/UIKit/UIApplication.cs:26
at MonoTouch.UIKit.UIApplication.Main (string[]) [0x00000] in /Users/plasma/Source/iphone/monotouch/UIKit/UIApplication.cs:31
at TextProblem.Application.Main (string[]) [0x00000] in /Users/admin/Projects/TextProblem/TextProblem/Main.cs:14
at (wrapper runtime-invoke) <Module>.runtime_invoke_void_object (object,intptr,intptr,intptr) <IL 0x00050, 0xffffffff>
Native stacktrace:
0 TextProblem 0x000d0db5 mono_handle_native_sigsegv + 343
1 TextProblem 0x0013afad sigabrt_signal_handler + 116
2 libSystem.B.dylib 0x9027246b _sigtramp + 43
3 ??? 0xffffffff 0x0 + 4294967295
4 libSystem.B.dylib 0x902ff89d raise + 26
5 libSystem.B.dylib 0x903159bc abort + 93
6 GraphicsServices 0x03edd558 GSRegisterPurpleNamedPort + 323
7 GraphicsServices 0x03edd715 GSEventInitialize + 220
8 UIKit 0x01c17229 UIApplicationMain + 643
9 ??? 0x09e09744 0x0 + 165713732
10 ??? 0x09e0967a 0x0 + 165713530
11 ??? 0x07ff2b96 0x0 + 134163350
12 ??? 0x07ff2ae2 0x0 + 134163170
13 ??? 0x07ff2b6d 0x0 + 134163309
14 TextProblem 0x0000f5c7 mono_jit_runtime_invoke + 1332
15 TextProblem 0x001ed281 mono_runtime_invoke + 137
16 TextProblem 0x001ef968 mono_runtime_exec_main + 669
17 TextProblem 0x001eed52 mono_runtime_run_main + 843
18 TextProblem 0x000a3153 mono_jit_exec + 200
19 TextProblem 0x002a16b8 main + 4155
20 TextProblem 0x00002949 _start + 208
21 TextProblem 0x00002878 start + 40
Debug info from gdb:
/tmp/mono-gdb-commands.C9e16B:1: Error in sourced command file:
unable to debug self
=================================================================
Got a SIGABRT while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries
used by your application.
=================================================================
Try resetting the simulator. iOS Simulator -> Reset Content and Settings. Note that this will reset the simulator to its default state.
You have a process hung in the simulator, a reboot should resolve this.
After the last update (4.0.0) I am having an issue and was wondering of this is a bug and is there a fix.
As you can see from the code below, I am creating a NavigationItem.RightBarButtonItem and adding a delegate to the TouchUpInside event. The button is created but when the touch occurs, the app dies a horribly(see below). Before this update the code ran perfect.
Anyone has any idea? Monotouch team, are you aware of this issue? Maybe I just coded incorrectly and worked before, but the new update has proven I was coding incorrect.
Regards,
Danny
CODE
//start by creating the view
RectangleF f = new RectangleF(0f,0f,38f,38f);
UIView v = new UIView(f);
//Now create a button with a background
UIButton b = new UIButton(f);
b.SetBackgroundImage(UIImage.FromFile("Images/Common/info.png"),UIControlState.Normal);
//add the button to the view
v.Add(b);
b.TouchUpInside
//give teh button a delegate action
b.TouchUpInside += delegate {
//var vc3 = new iPhone_HomeView();
//var vc3 = new iPhone_RetardView();
//vc3.Title = "asdasd";
//this.NavigationController.PushViewController (vc3, true);
};
//now apply the view to the navigation bar on the right
NavigationItem.RightBarButtonItem = new UIBarButtonItem(v);
NavigationItem.RightBarButtonItem.Width = 38f;
ERROR
Stacktrace:
at (wrapper managed-to-native) MonoTouch.UIKit.UIApplication.UIApplicationMain (int,string[],intptr,intptr)
at MonoTouch.UIKit.UIApplication.Main (string[],string,string) [0x00038] in /Users/plasma/Source/iphone/monotouch/UIKit/UIApplication.cs:26
at MonoTouch.UIKit.UIApplication.Main (string[]) [0x00000] in /Users/plasma/Source/iphone/monotouch/UIKit/UIApplication.cs:31
at SmartPhoneSolution.Application.Main (string[]) [0x00000] in /Users/aprdev/Projects/SmartPhoneSolution/SmartPhoneSolution/Main.cs:15
at (wrapper runtime-invoke) .runtime_invoke_void_object (object,intptr,intptr,intptr)
Native stacktrace:
0 SmartPhoneSolution1 0x000d0db5 mono_handle_native_sigsegv + 343
1 SmartPhoneSolution1 0x0000f80c mono_sigsegv_signal_handler + 322
2 libSystem.B.dylib 0x996fb45b _sigtramp + 43
3 ??? 0xffffffff 0x0 + 4294967295
4 UIKit 0x01b92de0 -[UIControl sendAction:to:forEvent:] + 67
5 UIKit 0x01b95262 -[UIControl(Internal) _sendActionsForEvents:withEvent:] + 527
6 UIKit 0x01b93e0f -[UIControl touchesEnded:withEvent:] + 458
7 UIKit 0x01b2b3d0 -[UIWindow _sendTouchesForEvent:] + 567
8 UIKit 0x01b0ccb4 -[UIApplication sendEvent:] + 447
9 UIKit 0x01b119bf _UIApplicationHandleEvent + 7672
10 GraphicsServices 0x05768822 PurpleEventCallback + 1550
11 CoreFoundation 0x00debff4 __CFRUNLOOP_IS_CALLING_OUT_TO_A_SOURCE1_PERFORM_FUNCTION__ + 52
12 CoreFoundation 0x00d4c807 __CFRunLoopDoSource1 + 215
13 CoreFoundation 0x00d49a93 __CFRunLoopRun + 979
14 CoreFoundation 0x00d49350 CFRunLoopRunSpecific + 208
15 CoreFoundation 0x00d49271 CFRunLoopRunInMode + 97
16 GraphicsServices 0x0576700c GSEventRunModal + 217
17 GraphicsServices 0x057670d1 GSEventRun + 115
18 UIKit 0x01b15af2 UIApplicationMain + 1160
19 ??? 0x0ba72744 0x0 + 195503940
20 ??? 0x0ba7267a 0x0 + 195503738
21 ??? 0x090bfb9e 0x0 + 151780254
22 ??? 0x090bfaea 0x0 + 151780074
23 ??? 0x090bfb75 0x0 + 151780213
24 SmartPhoneSolution1 0x0000f5c7 mono_jit_runtime_invoke + 1332
25 SmartPhoneSolution1 0x001ed281 mono_runtime_invoke + 137
26 SmartPhoneSolution1 0x001ef968 mono_runtime_exec_main + 669
27 SmartPhoneSolution1 0x001eed52 mono_runtime_run_main + 843
28 SmartPhoneSolution1 0x000a3153 mono_jit_exec + 200
29 SmartPhoneSolution1 0x002a16b8 main + 4155
30 SmartPhoneSolution1 0x00002949 _start + 208
31 SmartPhoneSolution1 0x00002878 start + 40
Debug info from gdb:
/tmp/mono-gdb-commands.WL0ypx:1: Error in sourced command file:
unable to debug self
=================================================================
Got a SIGSEGV while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries
used by your application.
Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object
at (wrapper managed-to-native) MonoTouch.UIKit.UIApplication:UIApplicationMain (int,string[],intptr,intptr)
at MonoTouch.UIKit.UIApplication.Main (System.String[] args, System.String principalClassName, System.String delegateClassName) [0x00038] in /Users/plasma/Source/iphone/monotouch/UIKit/UIApplication.cs:26
at MonoTouch.UIKit.UIApplication.Main (System.String[] args) [0x00000] in /Users/plasma/Source/iphone/monotouch/UIKit/UIApplication.cs:31
at SmartPhoneSolution.Application.Main (System.String[] args) [0x00000] in /Users/aprdev/Projects/SmartPhoneSolution/SmartPhoneSolution/Main.cs:15
I had a similar problem last week. It seems like MT 4 is more aggressive in it's GC than earlier versions, and things that I was able to get away with before are now causing problems.
Try declaring your UIButton at the class level, instead of scoping it locally.
Same thing happened to me porting existing Objective-C code. This solution is to make sure your button is an instance member of your class. This code works well (extra viewcontroller boilerplate code omitted):
public partial class HomeViewController : UIViewController
{
private UIButton _settingsButton;
public override void ViewDidLoad()
{
base.ViewDidLoad();
ConfigureNavigationBar();
}
private void ConfigureNavigationBar()
{
// Add the Settings icon to nav bar
_settingsButton = UIButton.FromType(UIButtonType.Custom);
_settingsButton.SetImage(UIImage.FromBundle("Images/settings.png"),
UIControlState.Normal);
_settingsButton.SizeToFit();
_settingsButton.TouchUpInside += (sender, e) =>
Console.WriteLine("clicked");
this.NavigationItem.RightBarButtonItem =
new UIBarButtonItem(_settingsButton);
}
}
See the last paragraph ("When to Keep References to Objects") in the MonoTouch documentation: API Design
I have written a PDF reader. It renders one page at a time. Using a swipe gesture the user can switch to the next page. If I keep switching pages fast enough (really, really fast) I get the error below. I tried to debug I do not get an exception in Monotouch.
Can somebody read sensible information from the stacktrace?
Stacktrace:
at (wrapper managed-to-native) MonoTouch.UIKit.UIApplication.UIApplicationMain (int,string[],intptr,intptr) <0x00004>
at (wrapper managed-to-native) MonoTouch.UIKit.UIApplication.UIApplicationMain (int,string[],intptr,intptr) <0x00004>
at MonoTouch.UIKit.UIApplication.Main (string[],string,string) [0x00038] in /Users/plasma/Source/iphone-3/monotouch/UIKit/UIApplication.cs:26
at MonoTouch.UIKit.UIApplication.Main (string[]) [0x00000] in /Users/plasma/Source/iphone-3/monotouch/UIKit/UIApplication.cs:31
at testBrowser.Application.Main (string[]) [0x00000] in /Users/itest/Documents/Develop/testBrowser/testBrowser/Main.cs:14
at (wrapper runtime-invoke) <Module>.runtime_invoke_void_object (object,intptr,intptr,intptr) <IL 0x0001d, 0x00043>
Native stacktrace:
0 testBrowser 0x000be9db mono_handle_native_sigsegv + 343
1 testBrowser 0x0000e7a6 mono_sigsegv_signal_handler + 313
2 libSystem.B.dylib 0x9118c46b _sigtramp + 43
3 ??? 0xffffffff 0x0 + 4294967295
4 QuartzCore 0x03035232 CABackingStoreCopyRenderImage + 64
5 QuartzCore 0x03035060 _ZN2CA6Render17copy_render_valueEPKvPFP12CGColorSpacevE + 212
6 QuartzCore 0x0303326d -[CALayer(CALayerPrivate) _copyRenderLayer:layerFlags:commitFlags:] + 434
7 QuartzCore 0x030330b4 CALayerCopyRenderLayer + 55
8 QuartzCore 0x030311d2 _ZN2CA7Context12commit_layerEP8_CALayerjjPv + 122
9 QuartzCore 0x030310e1 CALayerCommitIfNeeded + 323
10 QuartzCore 0x03031069 CALayerCommitIfNeeded + 203
11 QuartzCore 0x03031069 CALayerCommitIfNeeded + 203
12 QuartzCore 0x0301f7b9 _ZN2CA7Context18commit_transactionEPNS_11TransactionE + 1395
13 QuartzCore 0x0301f0d0 _ZN2CA11Transaction6commitEv + 292
14 QuartzCore 0x0304f7d5 _ZN2CA11Transaction17observer_callbackEP19__CFRunLoopObservermPv + 99
15 CoreFoundation 0x00dfafbb __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ + 27
16 CoreFoundation 0x00d900e7 __CFRunLoopDoObservers + 295
17 CoreFoundation 0x00d58bd7 __CFRunLoopRun + 1575
18 CoreFoundation 0x00d58240 CFRunLoopRunSpecific + 208
19 CoreFoundation 0x00d58161 CFRunLoopRunInMode + 97
20 GraphicsServices 0x03eb8268 GSEventRunModal + 217
21 GraphicsServices 0x03eb832d GSEventRun + 115
22 UIKit 0x01bf242e UIApplicationMain + 1160
23 ??? 0x09d31c41 0x0 + 164830273
24 ??? 0x09d31b7a 0x0 + 164830074
25 ??? 0x09d3157d 0x0 + 164828541
26 ??? 0x09d314b9 0x0 + 164828345
27 ??? 0x09d31514 0x0 + 164828436
28 testBrowser 0x0000e56a mono_jit_runtime_invoke + 1360
29 testBrowser 0x001c961b mono_runtime_invoke + 137
30 testBrowser 0x001cb2d7 mono_runtime_exec_main + 714
31 testBrowser 0x001cabfd mono_runtime_run_main + 812
32 testBrowser 0x00095354 mono_jit_exec + 200
33 testBrowser 0x0027d299 main + 3494
34 testBrowser 0x00003009 _start + 208
35 testBrowser 0x00002f38 start + 40
Debug info from gdb:
warning: .o file "/Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator.sdk/usr/lib/libmonotouch.a(monotouch-glue.x86.o)" more recent than executable timestamp in "/Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser"
warning: Could not open OSO file /Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator.sdk/usr/lib/libmonotouch.a(monotouch-glue.x86.o) to scan for pubtypes for objfile /Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser
warning: .o file "/Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator.sdk/usr/lib/libmonotouch.a(monotouch-x86.double-abi-stret-trampoline.o)" more recent than executable timestamp in "/Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser"
warning: Could not open OSO file /Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator.sdk/usr/lib/libmonotouch.a(monotouch-x86.double-abi-stret-trampoline.o) to scan for pubtypes for objfile /Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser
warning: .o file "/Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator.sdk/usr/lib/libmonotouch.a(gc.x86.o)" more recent than executable timestamp in "/Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser"
warning: Could not open OSO file /Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator.sdk/usr/lib/libmonotouch.a(gc.x86.o) to scan for pubtypes for objfile /Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser
warning: .o file "/Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator.sdk/usr/lib/libmonotouch.a(zlib-helper.x86.o)" more recent than executable timestamp in "/Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser"
warning: Could not open OSO file /Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator.sdk/usr/lib/libmonotouch.a(zlib-helper.x86.o) to scan for pubtypes for objfile /Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser
warning: Could not find object file "/var/folders/Ny/NyElTwhDGD8kZMqIEeLGXE+++TI/-Tmp-//ccvRqNHg.o" - no debug information available for "template.m".
warning: .o file "/Developer/usr/lib/gcc/i686-apple-darwin10/4.2.1/libgcc.a(_divdi3.o)" more recent than executable timestamp in "/Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser"
warning: Could not open OSO file /Developer/usr/lib/gcc/i686-apple-darwin10/4.2.1/libgcc.a(_divdi3.o) to scan for pubtypes for objfile /Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser
warning: .o file "/Developer/usr/lib/gcc/i686-apple-darwin10/4.2.1/libgcc.a(_moddi3.o)" more recent than executable timestamp in "/Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser"
warning: Could not open OSO file /Developer/usr/lib/gcc/i686-apple-darwin10/4.2.1/libgcc.a(_moddi3.o) to scan for pubtypes for objfile /Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser
warning: .o file "/Developer/usr/lib/gcc/i686-apple-darwin10/4.2.1/libgcc.a(_udivdi3.o)" more recent than executable timestamp in "/Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser"
warning: Could not open OSO file /Developer/usr/lib/gcc/i686-apple-darwin10/4.2.1/libgcc.a(_udivdi3.o) to scan for pubtypes for objfile /Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser
warning: .o file "/Developer/usr/lib/gcc/i686-apple-darwin10/4.2.1/libgcc.a(_umoddi3.o)" more recent than executable timestamp in "/Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser"
warning: Could not open OSO file /Developer/usr/lib/gcc/i686-apple-darwin10/4.2.1/libgcc.a(_umoddi3.o) to scan for pubtypes for objfile /Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser
warning: .o file "/Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator.sdk/usr/lib/libmonotouch.a(monotouch-glue.x86.o)" more recent than executable timestamp in "/Users/itest/Library/Application Support/iPhone Simulator/4.2/Applications/08D29A1D-AB54-49CC-9C55-FE763BB6BC37/testBrowser.app/testBrowser"
warning: Couldn't open object file '/Developer/MonoTouch/SDKs/MonoTouch.iphonesimulator.sdk/usr/lib/libmonotouch.a(monotouch-glue.x86.o)'
Attaching to process 17837.
Reading symbols for shared libraries . done
Reading symbols for shared libraries ........................................................................................................................... done
0x91131459 in read$UNIX2003 ()
15 0x9114ba12 in __workq_kernreturn ()
14 0x9114ba12 in __workq_kernreturn ()
13 0x911540a6 in __semwait_signal ()
12 "com.apple.CFSocket.private" 0x911450c6 in select$DARWIN_EXTSN ()
11 0x911260fa in mach_msg_trap ()
10 0x911540a6 in __semwait_signal ()
9 0x911540a6 in __semwait_signal ()
8 0x911b9a7e in poll$UNIX2003 ()
7 0x911540a6 in __semwait_signal ()
6 "WebThread" 0x911260fa in mach_msg_trap ()
5 0x911540a6 in __semwait_signal ()
4 0x91126136 in semaphore_wait_trap ()
3 0x911260fa in mach_msg_trap ()
2 "com.apple.libdispatch-manager" 0x9114c982 in kevent ()
* 1 "com.apple.main-thread" 0x91131459 in read$UNIX2003 ()
Thread 15 (process 17837):
#0 0x9114ba12 in __workq_kernreturn ()
#1 0x9114bfa8 in _pthread_wqthread ()
#2 0x9114bbc6 in start_wqthread ()
Thread 14 (process 17837):
#0 0x9114ba12 in __workq_kernreturn ()
#1 0x9114bfa8 in _pthread_wqthread ()
#2 0x9114bbc6 in start_wqthread ()
Thread 13 (process 17837):
#0 0x911540a6 in __semwait_signal ()
#1 0x91153d62 in _pthread_cond_wait ()
#2 0x911559f8 in pthread_cond_wait$UNIX2003 ()
#3 0x0022d0bc in _wapi_handle_timedwait_signal_handle (handle=0x101, timeout=0x0, alertable=1, poll=0) at ../../../../mono/io-layer/handles.c:1614
#4 0x0022ce70 in _wapi_handle_wait_signal_handle (handle=0x101, alertable=1) at ../../../../mono/io-layer/handles.c:1557
#5 0x00242a6e in WaitForSingleObjectEx (handle=0x101, timeout=4294967295, alertable=1) at ../../../../mono/io-layer/wait.c:205
#6 0x00201f39 in async_invoke_thread (data=0x0) at ../../../../mono/metadata/threadpool.c:1485
#7 0x00203836 in start_wrapper (data=0xda7eaa0) at ../../../../mono/metadata/threads.c:661
#8 0x00244c76 in thread_start_routine (args=0x706c680) at ../../../../mono/io-layer/wthreads.c:286
#9 0x002746eb in GC_start_routine (arg=0xa20aea0) at ../../../libgc/pthread_support.c:1390
#10 0x9115385d in _pthread_start ()
#11 0x911536e2 in thread_start ()
Thread 12 (process 17837):
#0 0x911450c6 in select$DARWIN_EXTSN ()
#1 0x00d8ccbc in __CFSocketManager ()
#2 0x9115385d in _pthread_start ()
#3 0x911536e2 in thread_start ()
Thread 11 (process 17837):
#0 0x911260fa in mach_msg_trap ()
#1 0x91126867 in mach_msg ()
#2 0x00dfb4a6 in __CFRunLoopServiceMachPort ()
#3 0x00d58874 in __CFRunLoopRun ()
#4 0x00d58240 in CFRunLoopRunSpecific ()
#5 0x00d58161 in CFRunLoopRunInMode ()
#6 0x01378162 in +[NSURLConnection(NSURLConnectionReallyInternal) _resourceLoadLoop:] ()
#7 0x01342d4c in -[NSThread main] ()
#8 0x01342cd8 in __NSThread__main__ ()
#9 0x9115385d in _pthread_start ()
#10 0x911536e2 in thread_start ()
Thread 10 (process 17837):
#0 0x911540a6 in __semwait_signal ()
#1 0x91153d62 in _pthread_cond_wait ()
#2 0x911559f8 in pthread_cond_wait$UNIX2003 ()
#3 0x0022d0bc in _wapi_handle_timedwait_signal_handle (handle=0x10f, timeout=0x0, alertable=1, poll=0) at ../../../../mono/io-layer/handles.c:1614
#4 0x0022ce70 in _wapi_handle_wait_signal_handle (handle=0x10f, alertable=1) at ../../../../mono/io-layer/handles.c:1557
#5 0x00242a6e in WaitForSingleObjectEx (handle=0x10f, timeout=4294967295, alertable=1) at ../../../../mono/io-layer/wait.c:205
#6 0x001fee14 in async_invoke_io_thread (data=0x0) at ../../../../mono/metadata/threadpool.c:369
#7 0x00203836 in start_wrapper (data=0xda38170) at ../../../../mono/metadata/threads.c:661
#8 0x00244c76 in thread_start_routine (args=0x706c604) at ../../../../mono/io-layer/wthreads.c:286
#9 0x002746eb in GC_start_routine (arg=0xa20aea0) at ../../../libgc/pthread_support.c:1390
#10 0x9115385d in _pthread_start ()
#11 0x911536e2 in thread_start ()
Thread 9 (process 17837):
#0 0x911540a6 in __semwait_signal ()
#1 0x91153d62 in _pthread_cond_wait ()
#2 0x911559f8 in pthread_cond_wait$UNIX2003 ()
#3 0x0022d0bc in _wapi_handle_timedwait_signal_handle (handle=0x10f, timeout=0x0, alertable=1, poll=0) at ../../../../mono/io-layer/handles.c:1614
#4 0x0022ce70 in _wapi_handle_wait_signal_handle (handle=0x10f, alertable=1) at ../../../../mono/io-layer/handles.c:1557
#5 0x00242a6e in WaitForSingleObjectEx (handle=0x10f, timeout=4294967295, alertable=1) at ../../../../mono/io-layer/wait.c:205
#6 0x001fee14 in async_invoke_io_thread (data=0x0) at ../../../../mono/metadata/threadpool.c:369
#7 0x00203836 in start_wrapper (data=0xd9305b0) at ../../../../mono/metadata/threads.c:661
#8 0x00244c76 in thread_start_routine (args=0x706c490) at ../../../../mono/io-layer/wthreads.c:286
#9 0x002746eb in GC_start_routine (arg=0xa20af60) at ../../../libgc/pthread_support.c:1390
#10 0x9115385d in _pthread_start ()
#11 0x911536e2 in thread_start ()
Thread 8 (process 17837):
#0 0x911b9a7e in poll$UNIX2003 ()
#1 0x00250781 in mono_poll (ufds=0x716c000, nfds=2, timeout=-1) at ../../../../mono/utils/mono-poll.c:8
#2 0x001ff1cd in socket_io_poll_main (p=0x35db20) at ../../../../mono/metadata/threadpool.c:495
#3 0x00203836 in start_wrapper (data=0xd9305b0) at ../../../../mono/metadata/threads.c:661
#4 0x00244c76 in thread_start_routine (args=0x706c414) at ../../../../mono/io-layer/wthreads.c:286
#5 0x002746eb in GC_start_routine (arg=0xa20af60) at ../../../libgc/pthread_support.c:1390
#6 0x9115385d in _pthread_start ()
#7 0x911536e2 in thread_start ()
Thread 7 (process 17837):
#0 0x911540a6 in __semwait_signal ()
#1 0x91153d62 in _pthread_cond_wait ()
#2 0x911559f8 in pthread_cond_wait$UNIX2003 ()
#3 0x0022d0bc in _wapi_handle_timedwait_signal_handle (handle=0x101, timeout=0x0, alertable=1, poll=0) at ../../../../mono/io-layer/handles.c:1614
#4 0x0022ce70 in _wapi_handle_wait_signal_handle (handle=0x101, alertable=1) at ../../../../mono/io-layer/handles.c:1557
#5 0x00242a6e in WaitForSingleObjectEx (handle=0x101, timeout=4294967295, alertable=1) at ../../../../mono/io-layer/wait.c:205
#6 0x00201f39 in async_invoke_thread (data=0x0) at ../../../../mono/metadata/threadpool.c:1485
#7 0x00203836 in start_wrapper (data=0xd917340) at ../../../../mono/metadata/threads.c:661
#8 0x00244c76 in thread_start_routine (args=0x706c2a0) at ../../../../mono/io-layer/wthreads.c:286
#9 0x002746eb in GC_start_routine (arg=0xa20af60) at ../../../libgc/pthread_support.c:1390
#10 0x9115385d in _pthread_start ()
#11 0x911536e2 in thread_start ()
Thread 6 (process 17837):
#0 0x911260fa in mach_msg_trap ()
#1 0x91126867 in mach_msg ()
#2 0x00dfb4a6 in __CFRunLoopServiceMachPort ()
#3 0x00d58874 in __CFRunLoopRun ()
#4 0x00d58240 in CFRunLoopRunSpecific ()
#5 0x00d58161 in CFRunLoopRunInMode ()
#6 0x04f7e423 in RunWebThread ()
#7 0x9115385d in _pthread_start ()
#8 0x911536e2 in thread_start ()
Thread 5 (process 17837):
#0 0x911540a6 in __semwait_signal ()
#1 0x9117fee5 in nanosleep$UNIX2003 ()
#2 0x9117fe23 in usleep$UNIX2003 ()
#3 0x002774e0 in monotouch_pump_gc ()
#4 0x9115385d in _pthread_start ()
#5 0x911536e2 in thread_start ()
Thread 4 (process 17837):
#0 0x91126136 in semaphore_wait_trap ()
#1 0x0015b189 in finalizer_thread (unused=0x0) at ../../../../mono/metadata/gc.c:1026
#2 0x00203836 in start_wrapper (data=0x6e33210) at ../../../../mono/metadata/threads.c:661
#3 0x00244c76 in thread_start_routine (args=0x706c034) at ../../../../mono/io-layer/wthreads.c:286
#4 0x002746eb in GC_start_routine (arg=0x6ff8f60) at ../../../libgc/pthread_support.c:1390
#5 0x9115385d in _pthread_start ()
#6 0x911536e2 in thread_start ()
Thread 3 (process 17837):
#0 0x911260fa in mach_msg_trap ()
#1 0x91126867 in mach_msg ()
#2 0x0011cfb2 in mach_exception_thread (arg=0x0) at ../../../../mono/mini/mini-darwin.c:138
#3 0x9115385d in _pthread_start ()
#4 0x911536e2 in thread_start ()
Thread 2 (process 17837):
#0 0x9114c982 in kevent ()
#1 0x9114d09c in _dispatch_mgr_invoke ()
#2 0x9114c559 in _dispatch_queue_invoke ()
#3 0x9114c2fe in _dispatch_worker_thread2 ()
#4 0x9114bd81 in _pthread_wqthread ()
#5 0x9114bbc6 in start_wqthread ()
Thread 1 (process 17837):
#0 0x91131459 in read$UNIX2003 ()
#1 0x000beb8b in mono_handle_native_sigsegv (signal=11, ctx=0xbfffb560) at ../../../../mono/mini/mini-exceptions.c:1826
#2 0x0000e7a6 in mono_sigsegv_signal_handler (_dummy=11, info=0xbfffb520, context=0xbfffb560) at ../../../../mono/mini/mini.c:4846
#3 <signal handler called>
#4 0x03035274 in CA::Render::Shmem::copy_image ()
#5 0x03035232 in CABackingStoreCopyRenderImage ()
#6 0x03035060 in CA::Render::copy_render_value ()
#7 0x0303326d in -[CALayer(CALayerPrivate) _copyRenderLayer:layerFlags:commitFlags:] ()
#8 0x030330b4 in CALayerCopyRenderLayer ()
#9 0x030311d2 in CA::Context::commit_layer ()
#10 0x030310e1 in CALayerCommitIfNeeded ()
#11 0x03031069 in CALayerCommitIfNeeded ()
#12 0x03031069 in CALayerCommitIfNeeded ()
#13 0x0301f7b9 in CA::Context::commit_transaction ()
#14 0x0301f0d0 in CA::Transaction::commit ()
#15 0x0304f7d5 in CA::Transaction::observer_callback ()
#16 0x00dfafbb in __CFRUNLOOP_IS_CALLING_OUT_TO_AN_OBSERVER_CALLBACK_FUNCTION__ ()
#17 0x00d900e7 in __CFRunLoopDoObservers ()
#18 0x00d58bd7 in __CFRunLoopRun ()
#19 0x00d58240 in CFRunLoopRunSpecific ()
#20 0x00d58161 in CFRunLoopRunInMode ()
#21 0x03eb8268 in GSEventRunModal ()
#22 0x03eb832d in GSEventRun ()
#23 0x01bf242e in UIApplicationMain ()
#24 0x09d31c41 in ?? ()
#25 0x09d31b7a in ?? ()
#26 0x09d3157d in ?? ()
#27 0x09d314b9 in ?? ()
#28 0x09d31514 in ?? ()
#29 0x0000e56a in mono_jit_runtime_invoke (method=0x80a83f4, obj=0x0, params=0xbfffed1c, exc=0x0) at ../../../../mono/mini/mini.c:4733
#30 0x001c961b in mono_runtime_invoke (method=0x80a83f4, obj=0x0, params=0xbfffed1c, exc=0x0) at ../../../../mono/metadata/object.c:2615
#31 0x001cb2d7 in mono_runtime_exec_main (method=0x80a83f4, args=0x9faec00, exc=0x0) at ../../../../mono/metadata/object.c:3581
#32 0x001cabfd in mono_runtime_run_main (method=0x80a83f4, argc=0, argv=0xbfffee54, exc=0x0) at ../../../../mono/metadata/object.c:3355
#33 0x00095354 in mono_jit_exec (domain=0x6f91e58, assembly=0x9b4b480, argc=1, argv=0xbfffee50) at ../../../../mono/mini/driver.c:1094
#34 0x0027d299 in main ()
=================================================================
Got a SIGSEGV while executing native code. This usually indicates
a fatal error in the mono runtime or one of the native libraries
used by your application.
=================================================================
Unhandled Exception: System.NullReferenceException: Object reference not set to an instance of an object
at (wrapper managed-to-native) MonoTouch.UIKit.UIApplication:UIApplicationMain (int,string[],intptr,intptr)
at MonoTouch.UIKit.UIApplication.Main (System.String[] args, System.String principalClassName, System.String delegateClassName) [0x00038] in /Users/plasma/Source/iphone-3/monotouch/UIKit/UIApplication.cs:26
It looks like you've allowed a backing store to get collected before iOS is done with it. More specifically an image or a layer.