[Mono-bugs] [Bug 75769][Nor] New - [REGRESSION] PInvoking with
CharSet.Auto causes assertion failure in runtime
bugzilla-daemon at bugzilla.ximian.com
bugzilla-daemon at bugzilla.ximian.com
Wed Aug 10 10:20:57 EDT 2005
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 nazgul at omega.pl.
http://bugzilla.ximian.com/show_bug.cgi?id=75769
--- shadow/75769 2005-08-10 10:20:57.000000000 -0400
+++ shadow/75769.tmp.2986 2005-08-10 10:20:57.000000000 -0400
@@ -0,0 +1,71 @@
+Bug#: 75769
+Product: Mono: Runtime
+Version: 1.0
+OS:
+OS Details: mono svn
+Status: NEW
+Resolution:
+Severity:
+Priority: Normal
+Component: interop
+AssignedTo: mono-bugs at ximian.com
+ReportedBy: nazgul at omega.pl
+QAContact: mono-bugs at ximian.com
+TargetMilestone: ---
+URL:
+Cc:
+Summary: [REGRESSION] PInvoking with CharSet.Auto causes assertion failure in runtime
+
+Please fill in this template when reporting a bug, unless you know what you
+are doing.
+Description of Problem:
+PInvoking with CharSet.Auto causes assertion failure in runtime
+(though I'm not an expert of PInvoke and it is possible that Auto is just
+invalid here)
+
+Steps to reproduce the problem:
+1. Compile and run following program with mono svn
+
+using System;
+using System.Runtime.InteropServices;
+
+class NativeReadLine
+{
+ [DllImport ("readline", CharSet = CharSet.Auto)]
+ static extern string readline (string x);
+
+ public string ReadLine (string prompt) {
+ Console.WriteLine ("read line");
+ return readline (prompt);
+ }
+}
+
+class HacksFramework
+{
+ public static void Main () {
+ // libreadline is broken on my machine, we need to call something
+ // in libtermcap.so to initialize it properly
+ try { tgetnum (""); } catch { }
+
+ NativeReadLine rl = new NativeReadLine ();
+ System.Console.WriteLine (rl.ReadLine ("bla"));
+ }
+
+ // helper call for making system load needed libs
+ [DllImport ("termcap", CharSet = CharSet.Auto)]
+ static extern int tgetnum (string x);
+}
+
+
+Actual Results:
+** ERROR **: file marshal.c: line 1143 (conv_to_icall): should not be reached
+aborting...
+
+
+Expected Results:
+bla
+
+How often does this happen?
+With mono svn always. With mono 1.1.8 it works fine.
+
+Additional Information:
More information about the mono-bugs
mailing list