Bug 3794 - OutOfMemory Exception thrown while debugging a MfA application that throws an exception
Summary: OutOfMemory Exception thrown while debugging a MfA application that throws an...
Status: RESOLVED DUPLICATE of bug 3778
Alias: None
Product: Xamarin Studio
Classification: Desktop
Component: Debugger ()
Hardware: PC Mac OS
: --- major
Target Milestone: ---
Assignee: Jeffrey Stedfast
Depends on:
Reported: 2012-03-07 16:30 UTC by Eric Beisecker
Modified: 2012-03-20 18:55 UTC (History)
2 users (show)

Is this bug a regression?: ---
Last known good build:

Simple Expand List Adapter Project (376.50 KB, application/zip)
2012-03-07 16:30 UTC, Eric Beisecker

Notice (2018-05-24): bugzilla.xamarin.com is now in read-only mode.

Please join us on Visual Studio Developer Community and in the Xamarin and Mono organizations on GitHub to continue tracking issues. Bugzilla will remain available for reference in read-only mode. We will continue to work on open Bugzilla bugs, copy them to the new locations as needed for follow-up, and add the new items under Related Links.

Our sincere thanks to everyone who has contributed on this bug tracker over the years. Thanks also for your understanding as we make these adjustments and improvements for the future.

Please create a new report on Developer Community or GitHub with your current version information, steps to reproduce, and relevant error messages or log files if you are hitting an issue that looks similar to this resolved bug and you do not yet see a matching new report.

Related Links:

Description Eric Beisecker 2012-03-07 16:30:04 UTC
Created attachment 1474 [details]
Simple Expand List Adapter Project

While debugging a certain part of the attached project, MonoDevelop throws an OutOfMemory Exception. 

Steps to Reproduce:
Open attached Project
Set a breakpoint at Line 77 in expandable_list_test.cs (mAdapter = new SimpleExpandableListAdapter ( // error here)
Run the Application
Click the 'Hello World' button
When breakpoint is hit continue execution
Click the 'Hello World' button again
This time step over the breakpoint. Exception occurs.

Mono 2.10.9
Mono for Android:

Run on Emulator API 10. 

ScreenShot: http://screencast.com/t/VsBeB8fyEl

System.OutOfMemoryException: Out of memory
  at (wrapper managed-to-native) string:InternalAllocateStr (int)
  at System.Text.StringBuilder.InternalEnsureCapacity (Int32 size) [0x00000] in <filename unknown>:0 
  at System.Text.StringBuilder.Append (Char value) [0x00000] in <filename unknown>:0 
  at Mono.Debugging.Evaluation.ObjectValueAdaptor.GetDisplayTypeName (System.String typeName, Int32 startIndex, Int32 endIndex) [0x001cb] in /Users/builder/data/lanes/monodevelop-mac- 
  at Mono.Debugging.Evaluation.ObjectValueAdaptor.GetDisplayTypeName (System.String typeName) [0x00000] in /Users/builder/data/lanes/monodevelop-mac- 
  at Mono.Debugging.Soft.SoftDebuggerBacktrace.CreateStackFrame (Mono.Debugger.Soft.StackFrame frame) [0x00159] in /Users/builder/data/lanes/monodevelop-mac- 
  at Mono.Debugging.Soft.SoftDebuggerBacktrace.GetStackFrames (Int32 firstIndex, Int32 lastIndex) [0x00026] in /Users/builder/data/lanes/monodevelop-mac- 
  at Mono.Debugging.Client.Backtrace.GetFrame (Int32 n) [0x00027] in /Users/builder/data/lanes/monodevelop-mac- 
  at Mono.Debugging.Client.Backtrace..ctor (IBacktrace serverBacktrace) [0x00025] in /Users/builder/data/lanes/monodevelop-mac- 
  at Mono.Debugging.Soft.SoftDebuggerSession.GetThreadBacktrace (Mono.Debugger.Soft.ThreadMirror thread) [0x00000] in /Users/builder/data/lanes/monodevelop-mac- 
  at Mono.Debugging.Soft.SoftDebuggerSession.HandleBreakEventSet (Mono.Debugger.Soft.Event[] es, Boolean dequeuing) [0x0022d] in /Users/builder/data/lanes/monodevelop-mac- 
  at Mono.Debugging.Soft.SoftDebuggerSession.HandleEventSet (Mono.Debugger.Soft.EventSet es) [0x00071] in /Users/builder/data/lanes/monodevelop-mac- 
  at Mono.Debugging.Soft.SoftDebuggerSession.EventHandler () [0x0002d] in /Users/builder/data/lanes/monodevelop-mac-
Comment 1 Eric Beisecker 2012-03-07 16:31:55 UTC
*Addendum* After Touching to the 'Hello World' button the first time, you must touch the 'Back' button and then touch the 'Hello World' button again to get the exception.
Comment 2 Jeffrey Stedfast 2012-03-07 17:31:02 UTC

*** This bug has been marked as a duplicate of bug 3778 ***
Comment 3 lindsey.driscoll 2012-03-20 18:55:59 UTC
Verified in git revision 862a2925f863d93cba4617fb9645af46651b8739 2.8.8-series