tomcat-dev mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From Rémy Maucherat <r...@apache.org>
Subject Re: svn commit: r1657910 - in /tomcat/tc7.0.x/trunk: ./ java/org/apache/coyote/http11/AbstractInputBuffer.java webapps/docs/changelog.xml
Date Sat, 07 Feb 2015 11:06:00 GMT
2015-02-07 1:34 GMT+01:00 Konstantin Kolinko <knst.kolinko@gmail.com>:

> The new code does not reset lastValid and pos in case when pos ==
> lastValid and both are > 0.
>
> It shall be
>
>         if (lastValid - pos > 0 && pos > 0) {
>             System.arraycopy(buf, pos, buf, 0, lastValid - pos);
>         }
>         lastValid = lastValid - pos;
>         pos = 0;
>

I agree it should be that, it looks less risky if the recycling does always
reset a clean state.

Rémy

Mime
  • Unnamed multipart/alternative (inline, None, 0 bytes)
View raw message