[Mono-bugs] [Bug 59004][Nor] New - Mono runtime does not free strings returned from P/Invoke

bugzilla-daemon@bugzilla.ximian.com bugzilla-daemon@bugzilla.ximian.com
Mon, 24 May 2004 23:26:13 -0400 (EDT)


Please do not reply to this email- if you want to comment on the bug, go to the
URL shown below and enter your comments there.

Changed by mathpup@mylinuxisp.com.

http://bugzilla.ximian.com/show_bug.cgi?id=59004

--- shadow/59004	2004-05-24 23:26:13.000000000 -0400
+++ shadow/59004.tmp.15579	2004-05-24 23:26:13.000000000 -0400
@@ -0,0 +1,44 @@
+Bug#: 59004
+Product: Mono: Runtime
+Version: unspecified
+OS: 
+OS Details: 
+Status: NEW   
+Resolution: 
+Severity: 
+Priority: Normal
+Component: misc
+AssignedTo: mono-bugs@ximian.com                            
+ReportedBy: mathpup@mylinuxisp.com               
+QAContact: mono-bugs@ximian.com
+TargetMilestone: ---
+URL: 
+Cc: 
+Summary: Mono runtime does not free strings returned from P/Invoke
+
+Description of Problem: 
+ 
+When a P/Invoke method specifies a string as its return type, the 
+unmanaged code actually returns a pointer to the string data. After 
+converting the data to a System.String, the .NET runtime attempts to free 
+the unmanaged storage, but the Mono runtime does not. The result is a 
+memory leak. 
+ 
+ 
+ 
+ 
+Steps to reproduce the problem: 
+1.  
+2.  
+3.  
+ 
+Actual Results: 
+ 
+ 
+Expected Results: 
+ 
+ 
+How often does this happen?  
+ 
+ 
+Additional Information: