So part of this is a mono bug, segfaults shouldn't be happening in managed code period.
I'm embedding mono 3 in a java app and consistently get the following when deserializing a simple protobuf message. Stacktrace: at <unknown> <0xffffffff> at (wrapper managed-to-native) System.Buffer.BlockCopyInternal (System.Array,int,System.Array,int,int) <0xffffffff> at System.Buffer.BlockCopy (System.Array,int,System.Array,int,int) <0x0006b> at System.IO.MemoryStream.Read (byte[],int,int) <0x000ff> at ProtoBuf.ProtoReader.Ensure (int,bool) <0x00237> at ProtoBuf.ProtoReader.TryReadUInt32VariantWithoutMoving (bool,uint&) <0x00043> at ProtoBuf.ProtoReader.TryReadUInt32Variant (uint&) <0x0001f> at ProtoBuf.ProtoReader.ReadFieldHeader () <0x00057> at (wrapper dynamic-method) com.game_machine.entity_system.generated.Entity.proto_2 (object,ProtoBuf.ProtoReader) <0x02802> at ProtoBuf.Serializers.CompiledSerializer.ProtoBuf.Serializers.IProtoSerializer.Read (object,ProtoBuf.ProtoReader) <0x0003f> at ProtoBuf.Meta.RuntimeTypeModel.Deserialize (int,object,ProtoBuf.ProtoReader) <0x00150> at ProtoBuf.Meta.TypeModel.DeserializeCore (ProtoBuf.ProtoReader,System.Type,object,bool) <0x00064> at ProtoBuf.Meta.TypeModel.Deserialize (System.IO.Stream,object,System.Type,ProtoBuf.SerializationContext) <0x0009b> at ProtoBuf.Meta.TypeModel.Deserialize (System.IO.Stream,object,System.Type) <0x0001f> at ProtoBuf.Serializer.Deserialize<T> (System.IO.Stream) <0x00043> at GameMachine.Actor.ByteArrayToEntity (byte[]) <0x00047> at GameMachine.TestActor.OnReceive (byte[]) <0x0006b> at (wrapper runtime-invoke) <Module>.runtime_invoke_void__this___object (object,intptr,intptr,intptr) <0xffffffff> This goes away if I just run in a single thread. It also takes an average of 10,000 iterations or so to trigger this error. I also tried wrapping all deserialization calls in a mutex but that had no effect. The threading model is such that none of the objects I am deserializing are accessed concurrently by different threads. Is protobuf-net completely reentrant, or does it try to reuse objects anywhere? This could very well all be a mono bug, but thought I would check here first to see if someone had any ideas. Chris -- You received this message because you are subscribed to the Google Groups "Protocol Buffers" group. To unsubscribe from this group and stop receiving emails from it, send an email to protobuf+unsubscr...@googlegroups.com. To post to this group, send email to protobuf@googlegroups.com. Visit this group at http://groups.google.com/group/protobuf. For more options, visit https://groups.google.com/groups/opt_out.