http://bugzilla.novell.com/show_bug.cgi?id=605295
http://bugzilla.novell.com/show_bug.cgi?id=605295#c0 Summary: Memory leak when marshaling an instance delegate Classification: Mono Product: Mono: Runtime Version: SVN Platform: Other OS/Version: openSUSE 11.3 Status: NEW Severity: Normal Priority: P5 - None Component: JIT AssignedTo: [email protected] ReportedBy: [email protected] QAContact: [email protected] Found By: --- Blocker: --- This test case makes memory grow quickly. It works fine if the instance delegate (cls.Run) is replaced by a delegate to a static method. using System; using System.Runtime.InteropServices; namespace DelegateTest { class MainClass { public static void Main (string[] args) { MainClass cls = new MainClass (); while (true) { uint id = g_timeout_add (500, cls.Run, IntPtr.Zero); g_source_remove (id); } } bool Run () { return false; } [DllImport("libglib-2.0.so")] static extern void g_source_remove (uint id); [DllImport("libglib-2.0.so")] static extern uint g_timeout_add (uint id, Func<bool> function, IntPtr data); } } -- Configure bugmail: http://bugzilla.novell.com/userprefs.cgi?tab=email ------- You are receiving this mail because: ------- You are the QA contact for the bug. _______________________________________________ mono-bugs maillist - [email protected] http://lists.ximian.com/mailman/listinfo/mono-bugs
