[Mono-dev] ArgumentNullException in GetSerializationCallbacks method

Vadim B. Guzev vguzev at yandex.ru
Thu Feb 15 17:19:36 EST 2007


Hey guys,

Now I caught new type of exception:
--8<----------------------------------------------
at System.Reflection.MonoCMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00000]
  at System.Reflection.MethodBase.Invoke (System.Object obj, System.Object[] parameters) [0x00000]
  at System.Runtime.Serialization.ObjectRecord.LoadData (System.Runtime.Serialization.ObjectManager manager, ISurrogateSelector selector, StreamingContext context) [0x00000]
  at System.Runtime.Serialization.ObjectManager.DoFixups () [0x00000]
  at System.Runtime.Serialization.Formatters.Binary.ObjectReader.ReadNextObject (System.IO.BinaryReader reader) [0x00000]
  at System.Runtime.Serialization.Formatters.Binary.ObjectReader.ReadObjectGraph (System.IO.BinaryReader reader, Boolean readHeaders, System.Object& result, System.Runtime.Remoting.Messaging.Header[]& headers) [0x00000]
  at System.Runtime.Serialization.Formatters.Binary.BinaryFormatter.NoCheckDeserialize (System.IO.Stream serializationStream, System.Runtime.Remoting.Messaging.HeaderHandler handler) [0x00000]
  at System.Runtime.Serialization.Formatters.Binary.BinaryFormatter.Deserialize (System.IO.Stream serializationStream) [0x00000]
  at MCSharp.Serialization.Deserialize (System.IO.Stream stream) [0x00000]
  at MCSharp.CommunicatorHandler.Handle () [0x00000]
  Environment.StackTrace:
   at MCSharp.MCException.WriteException ()
   at MCSharp.CommunicatorHandler.Handle ()
   at System.MulticastDelegate.invoke_void ()
  Inner exception: System.InvalidProgramException: Invalid IL code in (wrapper runtime-invoke) System.Object:runtime_invoke_void_SerializationInfo_StreamingContext (object,intptr,intptr,intptr): IL_0033: pop


  at <0x00000> <unknown method>
  at (wrapper managed-to-native) System.Reflection.MonoCMethod:InternalInvoke (object,object[])
  at System.Reflection.MonoCMethod.Invoke (System.Object obj, BindingFlags invokeAttr, System.Reflection.Binder binder, System.Object[] parameters, System.Globalization.CultureInfo culture) [0x00000]
--8<----------------------------------------------

What the hell is this?

Best regards,
Vadim

16.02.07, 00:59, Vadim B. Guzev <vguzev at yandex.ru>:

> > > Does it make sense? What do you think?
> > It doesn't make any sense because when obj.GetType () returns
> > null something in the runtime went wrong.
> > You can of course try the change out. The code is not vital unless
> > your code is relying on 2.0 serialization callbacks.
> I agree that it is not really correct solution, but at least it works...
> So, is it possible to make the same fixes in SVN? We can't force all our users to use those tricks with changing mono source code...
> Best regards,
> Vadim
> _______________________________________________
> Mono-devel-list mailing list
> Mono-devel-list at lists.ximian.com
> http://lists.ximian.com/mailman/listinfo/mono-devel-list



More information about the Mono-devel-list mailing list