This is the mail archive of the java-patches@gcc.gnu.org mailing list for the Java project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

Re: [PATCH]: DatagramChannel + Misc. Channel Fixes


On Sun, Feb 01, 2004 at 01:45:25PM -0600, Mohan Embar wrote:
> Hi Michael,
> 
> >Can you recreate this as unified diff please ? Its much more readbale.
> 
> Here you go....

Now I go ...

> -        int len = dst.remaining();
> +        int len = dst.capacity() - dst.position();

Why is this needed ? This means that we write probably more data into
the buffer then is suitable. I think we have to honor limit(). This is
automatically done by using remaining().

Can you write a little example proving I'm wrong ? (not that big NetTest
suite.


> -    int len = dst.remaining();
> +    int len = dst.capacity() - dst.position();

Same here.



Michael


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]