[Mono-bugs] [Bug 82400][Nor] Changed - [PATCH] DateTime binary serialization incompatible with MS.NET 2.0

bugzilla-daemon at bugzilla.ximian.com bugzilla-daemon at bugzilla.ximian.com
Tue Aug 21 14:26:49 EDT 2007


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 jaebird at gmail.com.

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

--- shadow/82400	2007-08-21 14:20:38.000000000 -0400
+++ shadow/82400.tmp.3527	2007-08-21 14:26:49.000000000 -0400
@@ -11,13 +11,13 @@
 AssignedTo: mono-bugs at ximian.com                            
 ReportedBy: jaebird at gmail.com               
 QAContact: mono-bugs at ximian.com
 TargetMilestone: ---
 URL: 
 Cc: alan.mcgovern at gmail.com,knocte at gmail.com,miguel at ximian.com,robertj at gmx.net
-Summary: DateTime binary serialization incompatible with MS.NET 2.0
+Summary: [PATCH] DateTime binary serialization incompatible with MS.NET 2.0
 
 Please fill in this template when reporting a bug, unless you know what you
 are doing.
 Description of Problem:
 
 This problem exposes itself when using DateTime as a parameter of a remote
@@ -151,6 +151,23 @@
 round trip with the extra DateTimeKind as well.
 
 ------- Additional Comments From jaebird at gmail.com  2007-08-21 14:20 -------
 Created an attachment (id=19853)
 Provides DateTime remoting support for .NET 2.0 profile
 
+
+------- Additional Comments From jaebird at gmail.com  2007-08-21 14:26 -------
+The above patch modifies the ObjectWriter and ObjectReader in
+class/corlib/System.Runtime.Serialization.Formatters.Binary.
+
+This modification checks for the NET_2_0 profile and uses the extra
+DateTimeKind info to both serialize and deserialize the DateTime
+object correctly. This has been tested between MS.NET 2.0 and Mono
+(Linux).
+
+At first it was thought that changing the DateTime class might be
+better. However, this seems to be a cleaner solution IMO.
+
+Note: This patch does NOT rely on Lionel's patch. In fact, this does
+not solve the standard Serialize/Deserialize issues. This only fixes
+the Remoting serialization as MS treats the DateTime as a primitive in
+remoting.


More information about the mono-bugs mailing list