[Mono-bugs] [Bug 55499][Nor] New - MS.NET and Mono serialization of Booleans incompatible
Fri, 12 Mar 2004 07:00:48 -0500 (EST)
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 firstname.lastname@example.org.
--- shadow/55499 2004-03-12 07:00:48.000000000 -0500
+++ shadow/55499.tmp.16941 2004-03-12 07:00:48.000000000 -0500
@@ -0,0 +1,64 @@
+Product: Mono: Class Libraries
+Summary: MS.NET and Mono serialization of Booleans incompatible
+Description of Problem:
+When I went to test Mono (0.30 under Windows), I found that it didn't work.
+ It was just a very simple UI control test. So I downloaded the latest
+class libraries from the website, and rebuilt them. No luck. Trudging
+through the error messages, I found this on the top of the error stack:
+Unhandled Exception: System.Runtime.Serialization.SerializationException:
+Field "m_value" not found in class System.Boolean
+Well, I had the class library source, so I went-a-hunting.
+Eventually, after getting an idea from the binary serialization format
+docs, I figured out the problem was the name of an internal variable in
+System.Boolean: it was `value' where MS.NET used `m_value'. So I fixed it
+up and... error disappeared! Of course, it was replaced with another one,
+but oh well; one step at a time.
+I've made a patch for the offending file, as well as a test case to see
+this for yourself. I'll attach them... once I work out HOW (it's my first
+Steps to reproduce the problem:
+1. Serialize a boolean using the MS .NET runtime
+2. Attempt to deserialize it with Mono
+Rather unpleasant error messages (see above)
+No error messages (oh, and a deserialized boolean, of course).
+How often does this happen?
+Every time with the latest (in so far as I know) version of corlib
+Can be fixed by changing the name of the internal variable `value' in
+corlib/System/Boolean.cs to `m_value'