What version are you using?  I thought 2.2.0 fixed this.

On Tue, Aug 25, 2009 at 7:37 AM, Srinivas G <srinigu...@gmail.com> wrote:

> Currently Message::ParseFromBoundedZeroCopyStream() doesn't guarantee
> that it will never attempt to read beyond the specified size.
> I have seen cases where a Next() is issued on the underlying stream,
> after the message has been successfully parsed, and the limit is hit.
> There is an implicit assumption in CodedInputStream limit management
> that reading past the limit will either return an EOF or some data
> which can be BackUp()ed onto the stream.
> This works well with files. However this can cause trouble when the
> underlying stream is a network socket.
> We may not hit EOF since the connection is open while the other side
> is waiting for the response; and there is no more data that can be
> read either. This can cause the Next() on the underlying stream to get
> blocked.
> Is it fine to fix this such a way that it will never attempt to read
> once the limit is hit?
> >

You received this message because you are subscribed to the Google Groups 
"Protocol Buffers" group.
To post to this group, send email to protobuf@googlegroups.com
To unsubscribe from this group, send email to 
For more options, visit this group at 

Reply via email to