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 [EMAIL PROTECTED]

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

--- shadow/80024        2007-04-22 21:10:21.000000000 -0400
+++ shadow/80024.tmp.31196      2007-05-10 14:15:33.000000000 -0400
@@ -109,6 +109,103 @@
 
 
 ------- Additional Comments From [EMAIL PROTECTED]  2007-04-22 21:10 -------
 I should mention, this is with SVN head. Have not been able to check
 against older versions or isolate the issue yet, but the same code
 does work on Mono x86 and MS.
+
+------- Additional Comments From [EMAIL PROTECTED]  2007-05-10 14:15 -------
+I isolated the issue a little (but don't have a standalone test case yet).
+
+(Here, DType is a byte-backed enum)
+
+object ReadType (Type type) {
+  object val;
+  DType dtype = Signature.TypeToDType (type);
+
+  //SIGABRT happens here, after ReadValue(DType) is called but before
+it is entered
+
+  val = ReadValue (dtype);
+  return val;
+}
+
+
+               public object ReadValue (DType dtype)
+               {
+                       //this point is not reached in failure cases
+
+                       switch (dtype)
+                       {
+                               case DType.Byte:
+                                       return ReadByte ();
+
+                               case DType.Boolean:
+                                       return ReadBoolean ();
+
+                               case DType.Int16:
+                                       return ReadInt16 ();
+
+                               case DType.UInt16:
+                                       return ReadUInt16 ();
+
+                               case DType.Int32:
+                                       return ReadInt32 ();
+
+                               case DType.UInt32:
+                                       return ReadUInt32 ();
+
+                               case DType.Int64:
+                                       return ReadInt64 ();
+
+                               case DType.UInt64:
+                                       return ReadUInt64 ();
+
+#if !DISABLE_SINGLE
+                               case DType.Single:
+                                       return ReadSingle ();
+#endif
+
+                               case DType.Double:
+                                       return ReadDouble ();
+
+                               case DType.String:
+                                       return ReadString ();
+
+                               case DType.ObjectPath:
+                                       return ReadObjectPath ();
+
+                               case DType.Signature:
+                                       return ReadSignature ();
+
+                               case DType.Variant:
+                                       return ReadVariant ();
+
+                               default:
+                                       return null;
+                               //      throw new Exception ("Unhandled D-Bus 
type: " + dtype);
+                       }
+               }
+
+
+
+This workaround (replacing the above two methods) works:
+
+object ReadType (Type type) {
+  object val;
+  DType dtype = Signature.TypeToDType (type);
+
+  //SIGABRT happens here, after ReadValue(DType) is called but before
+it is entered
+
+                               if (dtype == DType.Byte)
+                                       val = ReadByte ();
+                               else if (dtype == DType.UInt32)
+                                       val = ReadUInt32 ();
+                               else if (dtype == DType.Boolean)
+                                       val = ReadBoolean ();
+                               else
+                                       throw new Exception ("This case is not 
important");
+
+  return val;
+}
+
_______________________________________________
mono-bugs maillist  -  [email protected]
http://lists.ximian.com/mailman/listinfo/mono-bugs

Reply via email to