-
-
Notifications
You must be signed in to change notification settings - Fork 754
Closed
Description
I serialize an object directly into NetworkStream and on another socket side I try to deserialize this object from NetworkStream.
The serialized object size is 4 bytes. When I call MessagePackSerializer.Deserialize(_stream) it calls _stream.Read method 2 times.
In the first time it calls _stream.Read(buffer, 0, 65535) and this call returns 4 bytes,
in the second time it calls _stream.Read(buffer, 0, 65531) and the application hangs because there is no more data in the stream.
I think that deserializer requires more data that it needs to deserialize the object.
Is there any possibility to change the deserializer behavior in this case without involving any additional byte arrays and data copying? Or some fixes need to be made in the library?
Metadata
Metadata
Assignees
Labels
No labels