[Mono-bugs] [Bug 609285] App crashes randomly and also creates threads that seemed to be in wait state

bugzilla_noreply at novell.com bugzilla_noreply at novell.com
Thu May 27 03:24:57 EDT 2010


http://bugzilla.novell.com/show_bug.cgi?id=609285

http://bugzilla.novell.com/show_bug.cgi?id=609285#c3


Ash Sketch <info at sketchmd.com> changed:

           What    |Removed                     |Added
----------------------------------------------------------------------------
                 CC|                            |info at sketchmd.com

--- Comment #3 from Ash Sketch <info at sketchmd.com> 2010-05-27 07:24:55 UTC ---
Thanks Geoff for the quick response

I traced this to this code ...

public override void ViewDidLoad ()
{
base.ViewDidLoad ();

UIBarButtonItem OkButton = new UIBarButtonItem (UIBarButtonSystemItem.Save,
HandleOkTouchDown);

UIToolbar bar = new UIToolbar ();
bar.Frame = new RectangleF (0, 0, 75, 45);
bar.SetItems (new UIBarButtonItem[] { OkButton }, true);        
       
navigationController.TopViewController.NavigationItem.RightBarButtonItem = new
UIBarButtonItem (bar);

}

Still not sure why the above code is problematic sometimes. 

Anyway, I changed this code to 

Moved OkButton and bar to be class variables of the controller class and
everything works fine now.

public override void ViewDidLoad ()
{
base.ViewDidLoad ();

 OkButton = new UIBarButtonItem (UIBarButtonSystemItem.Save,
HandleOkTouchDown);

bar = new UIToolbar ();
bar.Frame = new RectangleF (0, 0, 75, 45);
bar.SetItems (new UIBarButtonItem[] { OkButton }, true);        
       
navigationController.TopViewController.NavigationItem.RightBarButtonItem = new
UIBarButtonItem (bar);

}

Thx,
Ash

-- 
Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email
------- You are receiving this mail because: -------
You are the QA contact for the bug.


More information about the mono-bugs mailing list